How to use strtoull to convert a string to an unsigned long long in C

1 Answer

0 votes
#include <stdio.h>
#include <stdlib.h>

int main() {
	char s[] = "1903837276521308982";

	unsigned long long ull = strtoull(s, NULL, 10);

	printf("%llu", ull);

	char ch = getchar();

	return 0;
}



/*
run:

1903837276521308982

*/

 



answered Apr 10, 2022 by avibootz

Related questions

1 answer 217 views
1 answer 72 views
1 answer 211 views
211 views asked Aug 10, 2019 by avibootz
1 answer 82 views
1 answer 166 views
...