#include <stdio.h>
main()
{
char * str = "hello";
char * ptr = str;
char least = 127;
while (*ptr++)
least = (*ptr<least ) ?*ptr :least;
printf("%d",least);
}
Answer / susie
Answer :
0
Explanation:
After ‘ptr’ reaches the end of the string the value pointed
by ‘str’ is ‘\0’. So the value of ‘str’ is less than that of
‘least’. So the value of ‘least’ finally is 0.
| Is This Answer Correct ? | 2 Yes | 0 No |
plz send me all data structure related programs
why the range of an unsigned integer is double almost than the signed integer.
int main() { int x=10; printf("x=%d, count of earlier print=%d", x,printf("x=%d, y=%d",x,--x)); getch(); } ================================================== returns error>> ld returned 1 exit status =================================================== Does it have something to do with printf() inside another printf().
#if something == 0 int some=0; #endif main() { int thing = 0; printf("%d %d\n", some ,thing); }
Give a oneline C expression to test whether a number is a power of 2?
25 Answers EA Electronic Arts, Google, Motorola,
print a semicolon using Cprogram without using a semicolon any where in the C code in ur program!!
35 Answers Tata Elxsi, TCS, VI eTrans,
#include<stdio.h> main() { struct xx { int x; struct yy { char s; struct xx *p; }; struct yy *q; }; }
write a c program to Reverse a given string using string function and also without string function
Write a program to check whether the number is prime and also check if it there i n fibonacci series, then return true otherwise return false
why nlogn is the lower limit of any sort algorithm?
how to return a multiple value from a function?
String reverse with time complexity of n/2 with out using temporary variable.