Re: Array's in Euphoria
- Posted by Ralf Nieuwenhuijsen <nieuwen at XS4ALL.NL> Apr 25, 1998
- 1015 views
>Hi guys >Ok still can't get it to do what I want,so here it is aiagin >What I want to do is take a data file and trun that into an Euphoria array. Well, there are several ways, but if you want to maintain the structure your sequence with the data, using EDOM could make your life a lot easier: -- Example code begins: include edom.e sequence my_seq my_seq = {"BlaBlaBla", 4, 5, {{ 344345.2343, 'f' },"" } } if edo_save ("myfile.edo", myseq, CP_NONE) -- (No compression) puts(1,"Unable to store data in myfile.edo") abort(1) end if -- You can load it back up at any time: sequence my_seq2 my_seq2 = edo_load ("myfile.edo", CP_NONE) -- Now my_seq2 contains the same data as my_seq did EDOM saves a sequence to disk at a pretty efficient way, and you can load it back just as easily. It is also *lots* of faster than using print () and get () Well, print () goes faster dan edo_save (), but get () goes 100 times or so slower than edo_load (), prolly because get () is an Euphoria include file, and thus not a built-in optimized piece of code. >I have tried append,&, and nothing is doing it.This does not make sence I >can program in Liberty Basic,Commodre Basic,GW Basic,but I can not get this >Euphoria at all.I have been trying for 2 years I have gone through David's >ABGTA 2 times I can print to screen or disk,I can open a file,do other >little things,I have tried looking at other programs and I get so lost,I can >use an eclude file if I have to,but I know that there is an answer as you >know being a programer I don't give up very easyly,I have a program almost >done in Liberty but I do like the speed in Euphoria,and this is to Robert I If you like the speed, and prefer basic, go get yourself PowerBasic, it compiles basic to extremely fast machine code. (beats Turbo C in optimization..) >am sorry for asking about programing in windows a few years back,WHAT A ! >!!!. >Liberty is easyer in that respect because they have a program that writes >the code to do windows. and to you Christian programers out there praise >god. >ok I done . >In Christ I do not have anything against people expressing their beliefs, nor do I want to start a flame war, but.. Why is every1 expressing their beliefs ? Do they want to be appriciated or more positivily judged by other because of their beliefs ? No offence, but I keep wondering, why tell the world 'that you're also a member of that club' unless you think that people might have more respect for you, which shouldn't be a good thing IMHO. Ralf Nieuwenhuijsen nieuwen at xs4all.nl PS Warning: The edom version at RDS' site contains a couple of bugs, it might be better if Robert removed the link for now. As soon as I get my self some floppy disk, I can copy the 'bug-free' version from my old computer (don't have any disk, this is the CDROM-age I guess)