two progs are given. one starts counting frm 0 to MAX and
the other stars frm MAX to 0. which one executes fast.

Answers were Sorted based on User's Feedback



two progs are given. one starts counting frm 0 to MAX and the other stars frm MAX to 0. which one e..

Answer / pritam

this may very well depend upon the architecture of the
underlying hardware.
On most arch though the second one max to 0 will run faster
because almost any sane compiler will optimize the code by
using "not zero" testing machine instruction which is
provided on almost all platforms.

Is This Answer Correct ?    5 Yes 0 No

two progs are given. one starts counting frm 0 to MAX and the other stars frm MAX to 0. which one e..

Answer / sriharsha karanth

Both Will Execute Fast

Is This Answer Correct ?    1 Yes 0 No

two progs are given. one starts counting frm 0 to MAX and the other stars frm MAX to 0. which one e..

Answer / nagel

what you have given for this is wrong there is some formula

Is This Answer Correct ?    0 Yes 0 No

two progs are given. one starts counting frm 0 to MAX and the other stars frm MAX to 0. which one e..

Answer / venkatesh

depends on program

Is This Answer Correct ?    0 Yes 0 No

two progs are given. one starts counting frm 0 to MAX and the other stars frm MAX to 0. which one e..

Answer / vignesh1988i

as for as i think , counting of MAX to 0 only will be done
fast..... take an real time example : when we climb up any
thing (eg : steps) it will take time for us to reach the
place which is up , wheares when we come down using steps we
feel easier and come quickly . like this if we see the
above can be the answer..................


thank u

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C Interview Questions

Give a one-line C expression to test whether a number is a power of 2. [No loops allowed - it's a simple test.]

0 Answers  


What is include directive in c?

0 Answers  


Write a program to input the price of 1 burger and the number of burgers eaten by a group of friends .print the total amount to be paid by the group?

0 Answers  


can we initialize all the members of union?

2 Answers  


how to find string length wihtout using c function?

6 Answers  






Write a program in C to convert date displayed in gregorian to julian date

0 Answers   HCL, Wipro,


who invented c

13 Answers   IBM,


The difference between printf and fprintf is ?

0 Answers   Baan Infotech,


Explain Basic concepts of C language?

0 Answers   EXL,


How can I make sure that my program is the only one accessing a file?

0 Answers  


how to print electricity bill according to following charges first 100 units -1rs per unit for next 200 units-1.50 rs per unit without using conditions

0 Answers  


Are enumerations really portable?

0 Answers  


Categories