+ 2
How to find the given no is odd or even using pointer to structure
C language
6 Answers
+ 1
look at the (LSB) least significant bit using the & operator to any particular integer to which you are pointing at within the structure. We need code to know exactly what you are doing though.
:)
if(num->n & 1)
{
printf("odd");
}
else
printf("even");
return 0;
+ 2
Any one solve this
+ 2
Ok thanks for your response
+ 2
Ok
0
try by yourself first, then ask for help here if you encounter any issues.
https://www.sololearn.com/discuss/1316935/?ref=app
0
just show your attempt, even if it doesn't work, we will try to fix it.