Write code for atoi(x) where x is hexadecimal string.
Answer Posted / audrius
long l = strtol(string, NULL, 16);
//or, if you need unsigned (which you usually do with hexes)
unsigned long ul = strtoul(string, NULL, 16);
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is structure of c program?
Is array a primitive data type in c?
write a program fibonacci series and palindrome program in c
What is function prototype in c with example?
Which operators cannot be overloaded a) Sizeof b) .* c) :: d) all of the above
Tell us two differences between new () and malloc ()?
Q.1 write a program to create binary tree 1 to 16 numbers? Q.2 write a program to creat a binary search tree for the member that is given by user?
How many bytes is a struct in c?
Ow can I insert or delete a line (or record) in the middle of a file?
Why is c called "mother" language?
How do I round numbers?
In C, What is the #line used for?
What is c system32 taskhostw exe?
.main() { char *p = "hello world!"; p[0] = 'H'; printf("%s",p); }
What is wild pointer in c?