@Nikhil the size of pointer is same as int i guess...so it differs on diff machines...im not sure abt ur OS and architecture doubt tho...
On Sat, Jul 30, 2011 at 8:02 PM, Nikhil Gupta <[email protected]>wrote: > One more query. What if the architecture is 64 bit, but the OS is 32 bit? > (Example windows XP) > > What will be the size of a pointer variable then? > > > On Sat, Jul 30, 2011 at 8:00 PM, Nikhil Gupta > <[email protected]>wrote: > >> @Aditi, Isn't the size of int variable 4 bytes in both the architectures? >> >> On Sat, Jul 30, 2011 at 12:52 PM, aditi garg >> <[email protected]>wrote: >> >>> it can also be found out by using printf("%d",sizeof(int)*8); >>> Correct me if i am wrong... >>> >>> >>> On Sat, Jul 30, 2011 at 11:55 AM, rajeev bharshetty < >>> [email protected]> wrote: >>> >>>> If pointer size is 4bytes then it is 32 bit machine and if 8 bytes it is >>>> 64 bit >>>> >>>> >>>> On Sat, Jul 30, 2011 at 11:51 AM, Nikhil Gupta < >>>> [email protected]> wrote: >>>> >>>>> How do you find out if a machine is 32 bit or 64 bit? >>>>> >>>>> I was thinking since the size of pointer variable is different in the 2 >>>>> configurations, we can declare a pointer and use sizeof() >>>>> Will that work? >>>>> Any other suggestions? >>>>> >>>>> -- >>>>> Nikhil Gupta >>>>> >>>>> -- >>>>> You received this message because you are subscribed to the Google >>>>> Groups "Algorithm Geeks" group. >>>>> To post to this group, send email to [email protected]. >>>>> To unsubscribe from this group, send email to >>>>> [email protected]. >>>>> For more options, visit this group at >>>>> http://groups.google.com/group/algogeeks?hl=en. >>>>> >>>> >>>> >>>> >>>> -- >>>> Regards >>>> Rajeev N B <http://www.opensourcemania.co.cc> >>>> >>>> "*Winners Don't do Different things , they do things Differently"* >>>> >>>> -- >>>> You received this message because you are subscribed to the Google >>>> Groups "Algorithm Geeks" group. >>>> To post to this group, send email to [email protected]. >>>> To unsubscribe from this group, send email to >>>> [email protected]. >>>> For more options, visit this group at >>>> http://groups.google.com/group/algogeeks?hl=en. >>>> >>> >>> >>> >>> -- >>> Aditi Garg >>> Undergraduate Student >>> Electronics & Communication Divison >>> NETAJI SUBHAS INSTITUTE OF TECHNOLOGY >>> Sector 3, Dwarka >>> New Delhi >>> >>> >>> -- >>> You received this message because you are subscribed to the Google Groups >>> "Algorithm Geeks" group. >>> To post to this group, send email to [email protected]. >>> To unsubscribe from this group, send email to >>> [email protected]. >>> For more options, visit this group at >>> http://groups.google.com/group/algogeeks?hl=en. >>> >> >> >> >> -- >> Nikhil Gupta >> Senior Co-ordinator, Publicity >> CSI, NSIT Students' Branch >> NSIT, New Delhi, India >> >> > > > -- > Nikhil Gupta > Senior Co-ordinator, Publicity > CSI, NSIT Students' Branch > NSIT, New Delhi, India > > -- > You received this message because you are subscribed to the Google Groups > "Algorithm Geeks" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/algogeeks?hl=en. > -- Aditi Garg Undergraduate Student Electronics & Communication Divison NETAJI SUBHAS INSTITUTE OF TECHNOLOGY Sector 3, Dwarka New Delhi -- You received this message because you are subscribed to the Google Groups "Algorithm Geeks" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.
