Count the number of 3 number appers between 0-3333 - Printable Version +- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums) +-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP) +--- Forum: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners) +--- Thread: Count the number of 3 number appers between 0-3333 (/Thread-Count-the-number-of-3-number-appers-between-0-3333) |
Count the number of 3 number appers between 0-3333 - SaranKumarV - 09-17-2010 Hi, Could some one please tell me how to count occurence of 3digit between 3 and 3333. I tried with the following code I am getting the numbers which contain 3 in the number but problem comes when there is number like (3000) which prints 4 times since length of the number (3000) is 4. Code: For i=3 to 3333 RE: Count the number of 3 number appers between 0-3333 - rdemers25 - 09-20-2010 Why wouldn't you try this? If the answer is 1336, then this works. Code: for i = 1 to 3333 |