Bibliography Maker
Author |
Message |
andrew.
|
Posted: Mon May 05, 2008 4:30 pm Post subject: Bibliography Maker |
|
|
I was making this program so I can enter in the information and it makes my bibliography, but for some reason, when it gets to the part where it gets the title from the user, it just skips the last get line. Try it.
Turing: |
setscreen ("graphics")
var num_of_entries : int
put "How many books would you like to register in the database?"
get num_of_entries
var title, author, publisher, datepublished, placepublished : array 1 .. num_of_entries of string
for i : 1 .. num_of_entries
put "What is the title of the book ", i, "?"
get title (i )
end for
put "Great!"
Input.Pause
for i : 1 .. num_of_entries
put "Who is the author(s) of ", title (i ), "?"
get author (i )
end for
put "Great!"
Input.Pause
for i : 1 .. num_of_entries
put "What is the publisher of ", title (i ), "?"
get publisher (i )
end for
put "Great!"
Input.Pause
for i : 1 .. num_of_entries
put "What is the date published of ", title (i ), "?"
get datepublished (i )
end for
put "Great!"
Input.Pause
for i : 1 .. num_of_entries
put "What is the place published for ", title (i ), "?"
get placepublished (i )
end for
put "Great!"
var stream : int
open : stream, "Bibliography.txt", put
for i : 1 .. num_of_entries
put : stream, "Bibliography"
put : stream, "Author, Title, Place Published, Publisher, Date Published"
put : stream, ""
put : stream, author (i ), ". ", title (i ), ". ", placepublished (i ), ": ", publisher (i ), ", ", datepublished (i )
put : stream, ""
end for
close : stream
put "Your file has been saved as 'Bibliography.txt'."
|
I've tried to play around with it adding different things but nothing changes it. |
|
|
|
|
|
Sponsor Sponsor
|
|
|
cavetroll
|
Posted: Mon May 05, 2008 5:19 pm Post subject: RE:Bibliography Maker |
|
|
I think your problem might be in the way you get your data. Try using
for getting the variables. This just allows for a whole line of text to be entered. |
|
|
|
|
|
andrew.
|
Posted: Mon May 05, 2008 5:24 pm Post subject: RE:Bibliography Maker |
|
|
Thank you. Good karma for you! |
|
|
|
|
|
|
|