WRITE A PROGRAM TO PRINT THE FOLLOWING OUTPUTS USING FOR LOOPS. A) * B) ***** *** * * ***** * * *****
2 15757Write an implementation of “float stringToFloat(char *str).” The code should be simple, and not require more than the basic operators (if, for, math operators, etc.). • Assumptions • Don’t worry about overflow or underflow • Stop at the 1st invalid character and return the number you have converted till then, if the 1st character is invalid return 0 • Don’t worry about exponential (e.g. 1e10), instead you should treat ‘e’ as an invalid character • Write it like real code, e.g. do error checking • Go though the string only once • Examples • “1.23” should return 1.23 • “1a” should return 1 • “a”should return 0
6 10829a) Identify the following declarations. Ex. int i (integer variable) float a[l0](array of 10 real nos) int (*f())() void *f int (*f()) [] void *f int f[] [] [] char *(*f) () int (*f[]) [] float(*f) [] [] float **f int ******f
TCS,
2157How can I prevent other programmers from violating encapsulation by seeing the private parts of my class?
1 3861
The postoder traversal is 7,14,3,55,22,5,17 Then ur Inorder traversal is??? please help me on this
Explain heap and queue.
Write the syntax and purpose of a switch statement in C.
Differentiate abs() function from fabs() function.
How does pointer work in c?
where are auto variables stored? What are the characteristics of an auto variable?
What is function prototype in c language?
How can I convert a number to a string?
What are the restrictions of a modulus operator?
How important is structure in life?
An arrangement of information in memory in such a way that it can be easily accessed and processed by a programming language a) string b) data structure c) pointers d) array
Find duplicates in a file containing 6 digit number (like uid) in O (n) time.
How can I insert or delete a line (or record) in the middle of a file?
What is the main difference between calloc () and malloc ()?
What is far pointer in c?