Resources
Answers
Examples
Sign in
Get Started
What do you want to save?
Add Code snippet
New code examples
C
2021-09-27 23:51:03
c read lines from text file in to array
FILE *fp; // pointer to file char *file_name; // file path char cur_char; char *line = NULL; // line array size_t len = 0; ssize_t read; int counter = 0; //char content[MAX_NUM_LINES][MAX_LINE_LENGTH]; char strArray...
Add solution
C
2021-09-19 11:12:02
fgets c
<open file> while(fgets(<char array>, <size of array>, <file pointer>) != null)
Add solution
C
2021-09-11 01:23:05
get string for c
#include <stdio.h> int main() { char name[30]; printf("Enter name: "); fgets(name, sizeof(name), stdin); // read string printf("Name: "); puts(name); // display string return 0; }
Add solution
PHP
2021-09-05 19:46:01
how to request user input in php
<?php echo "What do you want to input? "; $input = rtrim(fgets(STDIN)); echo "I got it:\n" . $input;
Add solution
C
2021-09-04 22:56:01
fscanf stops at space
fgets(characterArrayToReadTo, maxCharactersToRead, filePointer);
Add solution
‹
1
2
3
›
Best helpers
daily
weekly
monthly
for 3 months
Sivasubramaniam Arunachalam
+5
Joker13
+5
Remmy Kasili
+5
Anand GV
+5
Manx rat
+5
Josh Mitchell
+5
show more
This website uses cookies to make IQCode work for you. By using this site, you agree to our
cookie policy
Welcome Back!
Sign up to unlock all of IQCode features:
Test your skills and track progress
Engage in comprehensive interactive courses
Commit to daily skill-enhancing challenges
Solve practical, real-world issues
Share your insights and learnings
Sign in
E-mail
Password
Recover lost password
Log in
Or log in with
Not registered?
Sign up takes less than a minute
Create a Free Account
Sign up to unlock all of IQCode features:
Test your skills and track progress
Engage in comprehensive interactive courses
Commit to daily skill-enhancing challenges
Solve practical, real-world issues
Share your insights and learnings
Sign up
Email
Password
Sign up for free
Or sign up with
By signing up, you agree to the
Terms and Conditions
and
Privacy Policy
. You also agree to receive product-related marketing emails from IQCode, which you can unsubscribe from at any time.