Answer to Question #53019 in C for sofia

Question #53019
how can i get the right output? #include <stdio.h> int main( ) { char status[] = {'s','i','m','p','l','e' } ; char i, x ; printf ( "Enter character to search: " ) ; scanf ( "%c", &x ) ; for(i=0;i<=5;i++) { if ( status[5] < x || status[i] >= x ) { if ( status[5] == x) printf ( "The character is at position %d in the array.", i ) ; else printf ( "character is not present in the array." ) ; break ; } } }
Expert's answer

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be first!

Leave a comment

Ask Your question

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS
paypal