Re: pu$�le

2010-07-17 Thread strtr
== Quote from Jonathan M Davis (jmdavisp...@gmail.com)'s article > On Saturday 17 July 2010 22:10:07 strtr wrote: > > == Quote from Jonathan M Davis (jmdavisp...@gmail.com)'s article > > > > > On Saturday 17 July 2010 18:59:18 strtr wrote: > > > > That is [dollar sign, euro sign] > > > > > > > > Th

Re: pu$�le

2010-07-17 Thread strtr
== Quote from Jonathan M Davis (jmdavisp...@gmail.com)'s article > On Saturday 17 July 2010 21:48:30 strtr wrote: > > == Quote from Jonathan M Davis (jmdavisp...@gmail.com)'s article > > > > > On Saturday 17 July 2010 18:59:18 strtr wrote: > > > > That is [dollar sign, euro sign] > > > > > > > > Th

Re: pu$�le

2010-07-17 Thread Jonathan M Davis
On Saturday 17 July 2010 22:10:07 strtr wrote: > == Quote from Jonathan M Davis (jmdavisp...@gmail.com)'s article > > > On Saturday 17 July 2010 18:59:18 strtr wrote: > > > That is [dollar sign, euro sign] > > > > > > The reason I post it is because I expected the stash to be 3 lower. > > > > We

Re: pu$�le

2010-07-17 Thread Jonathan M Davis
On Saturday 17 July 2010 21:48:30 strtr wrote: > == Quote from Jonathan M Davis (jmdavisp...@gmail.com)'s article > > > On Saturday 17 July 2010 18:59:18 strtr wrote: > > > That is [dollar sign, euro sign] > > > > > > The reason I post it is because I expected the stash to be 3 lower. > > > > As

Re: pu$�le

2010-07-17 Thread strtr
== Quote from Jonathan M Davis (jmdavisp...@gmail.com)'s article > On Saturday 17 July 2010 18:59:18 strtr wrote: > > That is [dollar sign, euro sign] > > > > The reason I post it is because I expected the stash to be 3 lower. > Well, if I replace writef with write, I get > I made $€8. > If I leave

Re: pu$�le

2010-07-17 Thread strtr
== Quote from Jonathan M Davis (jmdavisp...@gmail.com)'s article > On Saturday 17 July 2010 18:59:18 strtr wrote: > > That is [dollar sign, euro sign] > > > > The reason I post it is because I expected the stash to be 3 lower. > As to why it's not working right, change th foreach loop to this: > fo

Re: pu$�le

2010-07-17 Thread Jonathan M Davis
On Saturday 17 July 2010 18:59:18 strtr wrote: > That is [dollar sign, euro sign] > > The reason I post it is because I expected the stash to be 3 lower. As to why it's not working right, change th foreach loop to this: foreach(dchar coin; coins) { ... } Otherwise, instead of looping over each

Re: pu$�le

2010-07-17 Thread Jonathan M Davis
On Saturday 17 July 2010 18:59:18 strtr wrote: > That is [dollar sign, euro sign] > > The reason I post it is because I expected the stash to be 3 lower. Well, if I replace writef with write, I get I made $€8. If I leave in the writef though, I get this error: /home/jmdavis/Downloaded_Files/

Re: Equivalent of scanf

2010-07-17 Thread Jonathan M Davis
On Saturday 17 July 2010 16:21:04 Michael Koehmstedt wrote: > Thanks for the informative reply. > > I am getting a run-time error with to!int(str). Apparently to!() seems to > only support one-way converting other types to strings. That is part of > the reason why I was getting so confused in figu

Re: Equivalent of scanf

2010-07-17 Thread Jonathan M Davis
On Saturday 17 July 2010 16:35:11 torhu wrote: > On 18.07.2010 01:21, Michael Koehmstedt wrote: > > > > So there is no scanf equivalent, but there is also nothing similar to C++ > > cin with the<< operator? > > Equivalents of those are available in std.stream and std.cstream, but > those module

Re: pu$�le

2010-07-17 Thread strtr
That is [dollar sign, euro sign] The reason I post it is because I expected the stash to be 3 lower.

pu$�le

2010-07-17 Thread strtr
What does this program print? const char[] coins = `$�`; void main() { writef(`I made `); int stash = 0; scope(exit) writefln(stash,`.`); scope(failure) stash--; foreach(coin;coins) { scope(exit) stash++; scop

Re: CT usage only in executable

2010-07-17 Thread strtr
== Quote from torhu (n...@spam.invalid)'s article > On 15.07.2010 02:29, strtr wrote: > > Not that the memory is really significant compared to the rest of my > > program, > > but I have a few fairly large arrays I use only in compile time and I was > > wondering why dmd still includes those in th

Re: Equivalent of scanf

2010-07-17 Thread torhu
On 18.07.2010 01:21, Michael Koehmstedt wrote: So there is no scanf equivalent, but there is also nothing similar to C++ cin with the<< operator? Equivalents of those are available in std.stream and std.cstream, but those modules will probably go away in a while.

Re: Equivalent of scanf

2010-07-17 Thread Michael Koehmstedt
Thanks for the informative reply. I am getting a run-time error with to!int(str). Apparently to!() seems to only support one-way converting other types to strings. That is part of the reason why I was getting so confused in figuring out how to read in an integer value. But you guys pointed me to

Re: Equivalent of scanf

2010-07-17 Thread Michael Koehmstedt
== Quote from Michael Koehmstedt (mkoehmst...@runner.csub.edu)'s article > So there is no scanf equivalent, but there is also nothing similar to C++ cin > with > the << operator? I meant the >> operator, of course. *slaps forehead*

Re: Equivalent of scanf

2010-07-17 Thread Jonathan M Davis
On Saturday 17 July 2010 15:41:14 Michael Koehmstedt wrote: > I'm having trouble figuring out how to do formatted console input, > something like C scanf() or C++ templated stream input. Unfortunately, > console input isn't covered in much detail in TDPL book. There doesn't > appear to be much disc

Re: Equivalent of scanf

2010-07-17 Thread torhu
On 18.07.2010 00:41, Michael Koehmstedt wrote: I'm having trouble figuring out how to do formatted console input, something like C scanf() or C++ templated stream input. Unfortunately, console input isn't covered in much detail in TDPL book. There doesn't appear to be much discussion about the st

Equivalent of scanf

2010-07-17 Thread Michael Koehmstedt
I'm having trouble figuring out how to do formatted console input, something like C scanf() or C++ templated stream input. Unfortunately, console input isn't covered in much detail in TDPL book. There doesn't appear to be much discussion about the standard library at all, which was a bit disappoint

Re: CT usage only in executable

2010-07-17 Thread torhu
On 15.07.2010 02:29, strtr wrote: Not that the memory is really significant compared to the rest of my program, but I have a few fairly large arrays I use only in compile time and I was wondering why dmd still includes those in the executable (simple text search dug them up). As a workaround yo