Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Leader board
Index -> Programming, Turing -> Turing Submissions
View previous topic Printable versionDownload TopicRate TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
_justin_




PostPosted: Tue Jun 06, 2006 8:52 pm   Post subject: Leader board

alrighty now i am trying to make a leader board for my game but i can't get the seek part to work

i tryed
code:
seek : fn,*
but that doesn't seem to be working


code:
var name := "Justin"
var score := Rand.Int (1,100)
var fn : int

open : fn, "leaderboard.txt", put, seek,mod
seek : fn, *
put : fn, name, score : 10
close : fn


put "Top 10 Scores"
put ""
put "Name" : 11, "Score"
put "====================================="
open : fn, "leaderboard.txt", get
loop
    exit when eof (fn)
    get : fn, name, score
    put name, score : 10
end loop
close : fn



any suggestions??


edit: Never mind i got the problem fixed it was when i opened the file i had "put,seek" and i forgot to put "mod"


@mods: please close topic
Sponsor
Sponsor
Sponsor
sponsor
Display posts from previous:   
   Index -> Programming, Turing -> Turing Submissions
View previous topic Tell A FriendPrintable versionDownload TopicRate TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 1 Posts ]
Jump to:   


Style:  
Search: