| | |
Reading words from file
Please support our C advertiser: Programming Forums - DaniWeb Sister Site
![]() |
•
•
Join Date: Jan 2009
Posts: 106
Reputation:
Solved Threads: 5
Here you have a small example :
To better understand fscanf try viewing : http://irc.essex.ac.uk/www.iota-six....nf_fprintf.asp
C Syntax (Toggle Plain Text)
#include <stdio.h> main() { FILE *fp; fp = fopen("test.txt", "w"); fscanf(fp, "%s", buffer); printf("Read Buffer: %s\n", %buffer ); flcose(fp;); }
Last edited by jen140; Apr 19th, 2009 at 9:04 pm.
![]() |
Similar Threads
- Replace words in a file (Python)
- reading words into strings (C++)
- Reading .dat file data into an array (C#)
- open a file and divide its data in arrays (C)
- How to populate an array? from a FILE (C)
- A couple Qs (arrays, c++, and reading in text files) (C++)
- help reading from .txt file (C++)
- C++ File I/O (C++)
- Help with File Reading loop (C++)
- File parsing in 'C' (C)
Other Threads in the C Forum
- Previous Thread: Basic Prob in C
- Next Thread: You'd think I would know how to use strings by now, but...
Views: 603 | Replies: 6
| Thread Tools | Search this Thread |
Tag cloud for C
adobe ansi api array arrays bash binarysearch centimeter char convert copyanyfile copypdffile cprogramme createcopyoffile createprocess() csyntax directory drawing dynamic executable fflush file fork frequency getlasterror givemetehcodez global graphics gtkgcurlcompiling hardware highest homework i/o inches infiniteloop initialization interest km lazy linked linkedlist linux linuxsegmentationfault list locate logical_drives match matrix meter microsoft motherboard multi mysql open opendocumentformat opensource openwebfoundation owf pattern pdf performance pointer pointers posix power problem probleminc program programming pyramidusingturboccodes read recursion recv repetition scanf scheduling segmentationfault send shape socketprograming spoonfeeding stack standard strchr string strings structures student suggestions system systemcall test testautomation unix user voidmain() wab win32 win32api windows.h






..Now ive just got to implement my palindrone function. Thanks for the help guys.