By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,513 Members | 1,815 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,513 IT Pros & Developers. It's quick & easy.

problem here

P: 7
Create a notepad file named number.txt which consists of int type numbers separated with new lines on your hard disk. Write a program which read the numbers form this file and show them to screen, also display the total numbers in files and largest and smallest numbers to the screen.
May 28 '07 #1
Share this Question
Share on Google+
12 Replies


gpraghuram
Expert 100+
P: 1,275
Hi,
Basiaclly u ant to write a code to read the info from file using fgets and then sscanf to read the number and print it using printf.

Have u tried anything on this?
Tell us where r u stuck.?

Raghuram
May 28 '07 #2

P: 79
I love how they copy and paste the assignment/homework question as is...
May 28 '07 #3

100+
P: 208
I love how they copy and paste the assignment/homework question as is...
It's because they've left the work too long. Then they think that we'll just give them the code and they won't have to worry about it.
May 28 '07 #4

Savage
Expert 100+
P: 1,764
It's because they've left the work too long. Then they think that we'll just give them the code and they won't have to worry about it.
Agreed.

I guess that they must first feel it on their own skin.

That way they will learn a good lesson

Savage
May 28 '07 #5

Expert 10K+
P: 11,448
I love how they copy and paste the assignment/homework question as is...
Especially the demanding tense of the verbs in it: "do this, do that". It especially
doesn't make sense for the third person folks reading this here in this forum.
The only reaction it brings up for me is: "do it yourself and be a bit more polite
next time you show up here" ;-)

kind regards,

Jos
May 28 '07 #6

AdrianH
Expert 100+
P: 1,251
We should slap them around like they are doing to us.
................__.(__)..__
...............(__)l.....l(__)
...............l.=.ll..=.ll.=.l.__
...............l....ll.....ll....l(__)
...............l.=.ll=.=ll.=.ll.=.l
................l....ll.....ll....ll....l
.....__......l.=.ll=.=ll.=.ll.=.l
....l]...\.....l.................ll.=.l
......l.....\....l.....................l
......(.....(_/.......................l
......(.................................l
......(.................................l
........ ............................../
............ _......................./
...............l.....................l
SLAP! SLAP!

:D

(Got that from Facebook.)

Just a little courtesy is all we ask.

Adrian
May 28 '07 #7

Savage
Expert 100+
P: 1,764
We should slap them around like they are doing to us.
................__.(__)..__
...............(__)l.....l(__)
...............l.=.ll..=.ll.=.l.__
...............l....ll.....ll....l(__)
...............l.=.ll=.=ll.=.ll.=.l
................l....ll.....ll....ll....l
.....__......l.=.ll=.=ll.=.ll.=.l
....l]...\.....l.................ll.=.l
......l.....\....l.....................l
......(.....(_/.......................l
......(.................................l
......(.................................l
........ ............................../
............ _......................./
...............l.....................l
SLAP! SLAP!

:D

(Got that from Facebook.)

Just a little courtesy is all we ask.

Adrian

LOL

Savage
May 28 '07 #8

100+
P: 208
We should slap them around like they are doing to us.
................__.(__)..__
...............(__)l.....l(__)
...............l.=.ll..=.ll.=.l.__
...............l....ll.....ll....l(__)
...............l.=.ll=.=ll.=.ll.=.l
................l....ll.....ll....ll....l
.....__......l.=.ll=.=ll.=.ll.=.l
....l]...\.....l.................ll.=.l
......l.....\....l.....................l
......(.....(_/.......................l
......(.................................l
......(.................................l
........ ............................../
............ _......................./
...............l.....................l
SLAP! SLAP!

:D

(Got that from Facebook.)

Just a little courtesy is all we ask.

Adrian
Reminds me of the movie "The Master of Disguise" with Dana Carvey.
May 28 '07 #9

Savage
Expert 100+
P: 1,764
Reminds me of the movie "The Master of Disguise" with Dana Carvey.
Hmmm,u are right.

Savage
May 28 '07 #10

AdrianH
Expert 100+
P: 1,251
Reminds me of the movie "The Master of Disguise" with Dana Carvey.
Hmm, gotta go look that one up at imdb.


Adrian
May 29 '07 #11

100+
P: 208
Hmm, gotta go look that one up at imdb.


Adrian
Ya, its a fairly dumb movie....I wish I didn't know it :P
May 29 '07 #12

AdrianH
Expert 100+
P: 1,251
Ya, its a fairly dumb movie....I wish I didn't know it :P
Looks kinda funny.


Adrian
May 29 '07 #13

Post your reply

Sign in to post your reply or Sign up for a free account.