Re: [algogeeks] help with o/p why 0 comes???

2013-02-28 Thread gmagog...@gmail.com
I think this is because of type mismatch. You are enforcing your program to
read a floating point number in the way of reading a integer. And they have
totally different format. If you have -Wall turned on, you should see a
warning.

Yanan Cao


On Thu, Feb 28, 2013 at 1:41 PM, Shubham Sandeep  wrote:

> code snippet:
> *int main()
> {
> printf ("%d\n",(float)((int)(3.5/2)));
> return 0;
> }*
>
> --
> Regards,
> SHUBHAM SANDEEP
> IT 3rd yr.
> NIT ALD.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to algogeeks+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to algogeeks+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [algogeeks] Re:

2012-08-21 Thread gmagog...@gmail.com
@dave Nice explanation!


Yanan Cao



On Tue, Aug 21, 2012 at 10:32 AM, Dave  wrote:

> @Wladimirufc: You responded that the type is int. This data type (usually)
> is 32 bits in length, and stores integers in the twos-complement number
> system. See http://en.wikipedia.org/wiki/Two%27s_complement for an
> explanation of this number system. In this number system, the bits
> (numbered 0 to 31 from the right) have values 2^i (2 to the ith power) for
> i = 0, 1, ..., 30, while bit 31 has value -2^31.
>
> In your code, you set x to have a 1-bit in bit 31 and zeros elsewhere.
> Thus, the value of x is -2^31, which is the value printed by the first
> printf() statement. This value is negative, so the value is negated. In
> twos-complement arithmetic, a value is negated by complementing the value
> (switching 0s to 1s and 1s to 0s) and then adding 1. I.e., the statement x
> = -x is functionally equivalent to x = (~x) + 1. For your value of x, the
> resulting value is the same as the original value, so the second printf()
> statement also prints the value -2^31.
>
> I'm glad you asked this question because it is very important to
> understand how quantities are stored in C and how the arithmetic works.
>
> Dave
>
> On Tuesday, August 21, 2012 11:25:11 AM UTC-5, wladimirufc wrote:
>
>>  Somebody could explain to me why this happen:
>>  x = (1<<31);
>>  printf("%d\n",x);
>>  if(x<0) x = -x;
>>  printf("%d\n",x);
>>
>> Output:
>>
>> -2147483648
>> -2147483648
>>
>> Wladimir Araujo Tavares
>> *Federal University of Ceará 
>> Homepage  | 
>> Maratona|
>> *
>>
>>
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/algogeeks/-/7a3Wer6PRRQJ.
>
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks]

2012-08-21 Thread gmagog...@gmail.com
what type is x?

Yanan Cao



On Tue, Aug 21, 2012 at 9:25 AM, Wladimir Tavares wrote:

>  Somebody could explain to me why this happen:
>  x = (1<<31);
>  printf("%d\n",x);
>  if(x<0) x = -x;
>  printf("%d\n",x);
>
> Output:
>
> -2147483648
> -2147483648
>
> Wladimir Araujo Tavares
> *Federal University of Ceará 
> Homepage  | 
> Maratona|
> *
>
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] C concept on memory layout

2012-02-06 Thread gmagog...@gmail.com
I think you are right about p being in BSS segment and it does last even
the function finishes, however, you may need a pointer to get the data out
of p. Then you can read the data.

Correct me if i am wrong


On Mon, Feb 6, 2012 at 1:04 PM, Ravi Ranjan  wrote:

> i have a confusion in it
>
> #include 
> #include 
>
>
> void add(int,int);
>
> int main(int argc, char *argv[])
> {
>
> add(6,3);
> printf("%d",p);
>
>   system("PAUSE");
>   return 0;
> }
>
>
> void add(int a, int b)
> {
>   static int p;
> p = a+ b;
> }
>
>
> here the memory layout says variable "p" is in BSS segment ... so its an
> independent region from stack frame. when the function looses its scope
> from function defination(add) then still it should be alive... and can be
> recognized/used by other function(main) but it gves an error of unknown
> variable "p".  need the correct logic... if i m wrong...
>
> thanx
> ravi
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] MS written test

2011-09-07 Thread gmagog...@gmail.com
0xa == 0x 1010, which stands for all the even bits
0x5 == 0x 0101, which stands for all the odd bits

>>1 and <<1 means shifting odd to even and even to odd

then | means putting new even bits and odd bits together

Yanan Cao



On Wed, Sep 7, 2011 at 10:23 AM, teja bala wrote:

>
> Can anyone plzz xplain the code?
>
> public static int swapOddEvenBits(int x) {
>  return ( ((x & 0x) >> 1) | ((x & 0x) << 1) );
>  }
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: Aps

2011-09-07 Thread gmagog...@gmail.com
lmao

Yanan Cao



On Wed, Sep 7, 2011 at 10:14 AM, Don  wrote:

> Clearly you are sitting still looking at a "Route 66" sign.
> Don
>
> On Sep 7, 10:09 am, Mani Bharathi  wrote:
> > While traveling at uniform speed. U read a two digit no. after one hr
> > the number is reversed order. After another hour the number read is same
> > two digit number. What is the average speed?
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Aps

2011-09-07 Thread gmagog...@gmail.com
First number: 16
second : 61
third: 106

speed: 45

Yanan Cao



On Wed, Sep 7, 2011 at 10:09 AM, Mani Bharathi wrote:

> While traveling at uniform speed. U read a two digit no. after one hr
> the number is reversed order. After another hour the number read is same
> two digit number. What is the average speed?
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/algogeeks/-/IgIgl9HkbYUJ.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] apti!

2011-08-26 Thread gmagog...@gmail.com
@Rahul

Assume the productivity of each man is the same

let original number of man be x

The total workload= x*10*p
also workload = (x-10)(10+10)*p

solve it
so x=20

Yanan Cao



On Fri, Aug 26, 2011 at 1:21 PM, Rahul Verma  wrote:

> @yanan how it is 20.
>
> Rahul Verma
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/algogeeks/-/uIONcvrf6kUJ.
>
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] apti!

2011-08-26 Thread gmagog...@gmail.com
20?

Yanan Cao



On Fri, Aug 26, 2011 at 1:12 PM, priya ramesh <
love.for.programm...@gmail.com> wrote:

> A certain number of men can finish a piece of work in 10 days. If however
> there were 10 men less it will take 10 days more for the work to be
> finished. How
> many men were there originally?
>
> (a) 110 men
> (b) 130 men
> (c) 100 men
> (d) none of these
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: question on fork()

2011-08-22 Thread gmagog...@gmail.com
Infinite times
Yanan Cao



On Mon, Aug 22, 2011 at 2:43 PM, Don  wrote:

> // DO NOT RUN THIS! By inspection, how many times will it print "Hello
> world"?
> // If you find out by running it, that is cheating. Don't do it!
> int main()
> {
>  int i=0, j=0;
>  for(i = 0; i*j < 20; ++i)
>  {
>if (fork() > 0) ++j;
>else i = j =  0;
>printf("Hello world\n");
>  }
>  return 0;
> }
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] Re: question on fork()

2011-08-22 Thread gmagog...@gmail.com
I am getting 6 red and 8 green as expected using the original code
Yanan Cao



On Mon, Aug 22, 2011 at 2:38 PM, Yasir  wrote:

> Surprisingly, if I comment the last if condition ( which is AFTER red()
> call ), it is printing red only 6 times as expected..
> http://ideone.com/XMHzC
>
>  main()
> {
>   fork();
>   int color=fork();
>   if(color==0)
>   fork();
>   red();
> //if(color==0)
> //   fork();
>   green();
>   getch();
>
> }
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/algogeeks/-/1o7KQKelcswJ.
>
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] C output

2011-08-22 Thread gmagog...@gmail.com
output is 10 using gcc 4.5.2

Yanan Cao



On Mon, Aug 22, 2011 at 2:18 PM, sagar pareek  wrote:

> Yeah its o/p is 10 :)
>
>
> On Tue, Aug 23, 2011 at 12:45 AM, Deepak Garg wrote:
>
>> its output is
>>
>> 10
>>
>>
>> On Tue, Aug 23, 2011 at 12:03 AM, rohit  wrote:
>>
>>> #include
>>>
>>> #define max(a,b) (a>b?a:b)
>>>
>>>
>>> int main()
>>> {
>>>
>>>  int j=max(3+2,2+8);
>>>  printf("%d",j);
>>>
>>>return 0;
>>> }
>>>
>>>why this program show output as 9 ? please help me
>>>
>>> --
>>> You received this message because you are subscribed to the Google Groups
>>> "Algorithm Geeks" group.
>>> To post to this group, send email to algogeeks@googlegroups.com.
>>> To unsubscribe from this group, send email to
>>> algogeeks+unsubscr...@googlegroups.com.
>>> For more options, visit this group at
>>> http://groups.google.com/group/algogeeks?hl=en.
>>>
>>>
>>
>>
>> --
>> U.D.I.T
>>
>> Sent by Nokia OVI (c)
>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>
>
> --
> **Regards
> SAGAR PAREEK
> COMPUTER SCIENCE AND ENGINEERING
> NIT ALLAHABAD
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] novel written test

2011-06-27 Thread gmagog...@gmail.com
if( links can be melt and made into smaller links )
{
return 1;
}
else
{
return 2;
}
Yanan Cao



On Mon, Jun 27, 2011 at 4:09 PM, sourabh jakhar wrote:

> two
>
>
> On Tue, Jun 28, 2011 at 2:23 AM, amit the cool wrote:
>
>> A chain is broken into three pieces of equal lengths containing 3
>> links each. It is taken to a back smith to join into a single
>> continuous one . How many links are  to be opened to make it ?
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>>
>
>
> --
> SOURABH JAKHAR,(CSE)(3 year)
> ROOM NO 167 ,
> TILAK,HOSTEL
> 'MNNIT ALLAHABAD
>
> The Law of Win says, "Let's not do it your way or my way; let's do it the
> best way."
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] novel written test

2011-06-27 Thread gmagog...@gmail.com
Is it required that no two sons have the same age?

>From my view, the clue "my youngest is the youngest" only defines the
requirement that "the youngest one is unique", but he can still have two
older brothers of the same age. Please correct me if this is wrong.

Yanan Cao



On Mon, Jun 27, 2011 at 3:54 PM, amit kumar  wrote:

> @piyush..will u xplain plz.
> by d way 2 sons cant hav d same age(hope they r nt twins)
>
>
> On Tue, Jun 28, 2011 at 2:14 AM, Piyush Sinha wrote:
>
>> 1,6,6
>>
>>
>> On Tue, Jun 28, 2011 at 2:07 AM, amit the cool 
>> wrote:
>>
>>> Conversation between two mathematicians: first : I have three
>>> children. The product of their ages is 36 . If you sum their ages . it
>>> is exactly same as my neighbor's door number on my left. The second
>>> mathematician verifies the door number and says that the not
>>> sufficient . Then the first says " o.k one more clue is that my
>>> youngest is the youngest" Immediately the second mathematician
>>> answers . Can you answer the question asked by the first
>>> mathematician? What are the children ages?
>>>
>>> --
>>> You received this message because you are subscribed to the Google Groups
>>> "Algorithm Geeks" group.
>>> To post to this group, send email to algogeeks@googlegroups.com.
>>> To unsubscribe from this group, send email to
>>> algogeeks+unsubscr...@googlegroups.com.
>>> For more options, visit this group at
>>> http://groups.google.com/group/algogeeks?hl=en.
>>>
>>>
>>
>>
>> --
>> *Piyush Sinha*
>> *IIIT, Allahabad*
>> *+91-8792136657*
>> *+91-7483122727*
>> *https://www.facebook.com/profile.php?id=10655377926 *
>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] [brain teaser ] 18march

2011-03-18 Thread gmagog...@gmail.com
"and"

Yanan Cao



On Fri, Mar 18, 2011 at 1:00 PM, anuj maurice wrote:

> agree
>
>
> On Fri, Mar 18, 2011 at 10:05 PM, Kunal Patil  wrote:
>
>> Nothing !!!  :P  :P
>>
>> On Fri, Mar 18, 2011 at 1:02 PM, Lavesh Rawat wrote:
>>
>>> *A Riddle Problem Solution*
>>> *
>>> *What is one thing that all wise men, regardless of their religion or
>>> politics, agree is between heaven and earth
>>>
>>> Update Your Answers at : Click 
>>> Here
>>>
>>> Solution:
>>> Will be updated after 1 day
>>>
>>>
>>>
>>> --
>>>
>>> "Never explain yourself. Your friends don’t need it
>>> and your enemies won’t believe it" .
>>>
>>> --
>>> You received this message because you are subscribed to the Google Groups
>>> "Algorithm Geeks" group.
>>> To post to this group, send email to algogeeks@googlegroups.com.
>>> To unsubscribe from this group, send email to
>>> algogeeks+unsubscr...@googlegroups.com.
>>> For more options, visit this group at
>>> http://groups.google.com/group/algogeeks?hl=en.
>>>
>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>
>
> --
> regards ,
> Anuj Maurice
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.



Re: [algogeeks] How to print numbers from 1 to 100 without loop , without recursion , without #define statements , without goto statement

2011-03-16 Thread gmagog...@gmail.com
printf("1 2 3 4 5 6 7 8 9 10 11 12 13...");

no loop, no recursion, no define, no goto. HAHA : )


On Wed, Mar 16, 2011 at 12:30 PM, Carl Barton wrote:

> @kumar Your example is still recursion
>
>
> On 16 March 2011 16:46, kumar anurag  wrote:
>
>> ok guys...
>>
>>
>> On Wed, Mar 16, 2011 at 9:54 PM, himanshu kansal <
>> himanshukansal...@gmail.com> wrote:
>>
>>>
>>> class arr
>>> {static int i;
>>> public:
>>> arr()
>>> {
>>> cout<>> }
>>> };
>>> int arr::i=1;
>>>
>>> int main()
>>> {
>>> arr a[100];
>>>
>>> }
>>> On Wed, Mar 16, 2011 at 9:47 PM, kumar anurag >> > wrote:
>>>

 using two different functions calling one another ?

 like
 fun1()
 {
   fun2()
 }
 fun2()
 {
   fun1();

 }


 On Wed, Mar 16, 2011 at 9:39 PM, D.N.Vishwakarma@IITR <
 deok...@gmail.com> wrote:

> *
> *
> --
> *With Regards
> Deoki Nandan Vishwakarma
> IITR MCA
> Mathematics Department
> *
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>



 --
 Kumar Anurag

  --
 You received this message because you are subscribed to the Google
 Groups "Algorithm Geeks" group.
 To post to this group, send email to algogeeks@googlegroups.com.
 To unsubscribe from this group, send email to
 algogeeks+unsubscr...@googlegroups.com.
 For more options, visit this group at
 http://groups.google.com/group/algogeeks?hl=en.

>>>
>>>  --
>>> You received this message because you are subscribed to the Google Groups
>>> "Algorithm Geeks" group.
>>> To post to this group, send email to algogeeks@googlegroups.com.
>>> To unsubscribe from this group, send email to
>>> algogeeks+unsubscr...@googlegroups.com.
>>> For more options, visit this group at
>>> http://groups.google.com/group/algogeeks?hl=en.
>>>
>>
>>
>>
>> --
>> Kumar Anurag
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Algorithm Geeks" group.
>> To post to this group, send email to algogeeks@googlegroups.com.
>> To unsubscribe from this group, send email to
>> algogeeks+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/algogeeks?hl=en.
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.