|
Wordle 790 4/6*
β¬β¬π©π¨π¨
β¬π¨π©π¨β¬
π©β¬π©π©π©
π©π©π©π©π©
That second guess wasn't very bright!
|
|
|
|
|
Wordle 790 4/6
π¨β¬β¬β¬β¬
π¨β¬π©β¬π¨
β¬π¨π©π©β¬
π©π©π©π©π©
|
|
|
|
|
Wordle 790 5/6
π¨β¬β¬β¬β¬
β¬π¨π¨π¨β¬
π¨π¨π©β¬β¬
β¬π¨π©β¬π¨
π©π©π©π©π©
βThat which can be asserted without evidence, can be dismissed without evidence.β
β Christopher Hitchens
|
|
|
|
|
Wordle 790 4/6*
π¨β¬β¬β¬π¨
π¨π¨β¬π¨β¬
π¨β¬π¨π¨π©
π©π©π©π©π©
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
Wordle 790 5/6
π¨β¬β¬π¨β¬
π¨β¬π¨π¨β¬
π¨π¨β¬β¬π¨
π©π©β¬π¨π©
π©π©π©π©π©
|
|
|
|
|
Wordle 790 6/6
β¬β¬β¬β¬β¬
π¨β¬π¨β¬β¬
β¬β¬π©π¨π¨
π¨π¨π©π©β¬
π©β¬π©π©π©
π©π©π©π©π©
Still had to look up my last guess
|
|
|
|
|
Wordle 790 3/6
π¨β¬π©β¬π¨
β¬π¨π©π©β¬
π©π©π©π©π©
|
|
|
|
|
π¨β¬π©β¬π¨
π©π©π©π©π©
In a closed society where everybody's guilty, the only crime is getting caught. In a world of thieves, the only final sin is stupidity. - Hunter S Thompson - RIP
|
|
|
|
|
Wordle 790 5/6
🟨β¬β¬β¬🟨
🟩🟨β¬β¬β¬
🟩β¬β¬🟨β¬
🟩β¬β¬β¬🟨
🟩🟩🟩🟩🟩
Ok, I have had my coffee, so you can all come out now!
|
|
|
|
|
Wordle 790 2/6
β¬π¨π©β¬π©
π©π©π©π©π©
I cheated though, so there's that...
Jeremy Falcon
|
|
|
|
|
Wordle 790 4/6*
β¬π¨π¨π¨β¬
β¬β¬π©π¨π¨
π¨π¨π©β¬β¬
π©π©π©π©π©
|
|
|
|
|
Wordle 790 4/6
β¬β¬β¬β¬π¨
π¨β¬π¨π¨β¬
π©β¬π©π©π©
π©π©π©π©π©
"A little time, a little trouble, your better day"
Badfinger
|
|
|
|
|
|
One, two, three, four, five
Once I caught a muon live
Six, seven, eight, nine, ten
Then I let it go again
Why did you let it go?
Because it made my fingers glow.
Freedom is the freedom to say that two plus two make four. If that is granted, all else follows.
-- 6079 Smith W.
|
|
|
|
|
good one.
a poet
and we know it..
"A little time, a little trouble, your better day"
Badfinger
|
|
|
|
|
apparently your fingers you can count on to count the muon
|
|
|
|
|
Having nothing better to do at the moment, I'm re-writing some of my file-reading code.
Previously, I would wrap a FileStream in a StreamReader and call it good -- that's good enough for many simple tasks, but it has some issues when used with some more difficult tasks.
I'm still using a FileStream, but now I'm wrapping it in a family of classes which add some features and eliminate some shortcomings.
What irks me -- and has for a while -- is how FileStream.ReadByte() reports END-OF-FILE:
"The byte, cast to an Int32, or -1 if the end of the stream has been reached."
I do realize that this matches the behavior of C's fgetc function.
Basically, it means that you have to test every return value for -1 (EOF) -- YUCK! so inefficient.
But this isn't C, I would much rather have FileStream.ReadByte() throw an Exception when it hits EOF.
Assuming that FileStream.ReadByte() uses the ReadFile Windows API function, I'm sure that the FileStream class could have a method with the ability to raise an Exception when it hits the EOF -- allow the user to choose how EOF is reported.
And, no, testing for EOF and then throwing is not an option, as it doesn't remove the test, which is the whole issue.
So do I now need to look into writing my own version of FileStream and have it throw an Exception?
Note:
I read a blog post about file handling improvements in .net 6, but it didn't seem to address this.
It should be easy enough for them to add a ThrowOnEOF option.
P.S. File length is reported in bytes, not characters, so comparing file length to characters read (as you get with StreamReader when reading a file which contains multi-byte characters) is not a solution.
And also, in some cases (hopefully rare today), a file may be logically terminated with char 26 (Ctrl-Z) even if the file size in bytes is reported as larger. To support that, a reader must still test every character returned.
Edit: I just read the following on a Wikipedia page about Unicode:
"Control-D has been used to signal "end of file" for text typed in at the terminal on Unix / Linux systems. Windows, DOS, and older minicomputers used Control-Z for this purpose."
"Control-Z has commonly been used on minicomputers, Windows and DOS systems to indicate "end of file" either on a terminal or in a text file. Unix / Linux systems use Control-D to indicate end-of-file at a terminal."
modified 19-Aug-23 0:06am.
|
|
|
|
|
i have written several C++ specialized stream classes . this is of course obvious however i mention anyway i.e. viz. i merely rely on the file size . i have no experience w/ .NET as only now have begun learning it . having looked at the documentation i.e. viz. "FileStream.ReadByte() throw an Exception when it hits EOF. " "The byte, cast to an Int32, or -1 if the end of the stream has been reached." i was STUNNED as how the heck can one distinguish a legitimate 0xff byte value from EOF . π΅
modified 17-Aug-23 19:58pm.
|
|
|
|
|
0xFFFFFFFF
Edit: vs 0x000000FF
modified 19-Aug-23 15:37pm.
|
|
|
|
|
thank you for kind reply . please pardon my stupidity but will a legitimate byte value of 0xff not be converted to 0xFFFFFFFF as return value and thus be confused w/ EOF ? furthermore may i please inquire why file size is not being utilized in your code for this purpose . i assume a logical reason . i would be thankful to learn from my betters . thank you kindly
|
|
|
|
|
The legitimate values for bytes from the stream are indeed 0x00 thru 0xff. That is why the return value is an INT, allowing (int)-1 EOF to be distinguished from 0xff data.
Many many moons ago in an embedded system we wrote a serial comms reader that returned 0x00 thru 0xff for received data, and a number of negative ints indicating different error conditions.
Software rusts. Simon Stephenson, ca 1994. So does this signature. me, 2012
|
|
|
|
|
thank you . i finally realized the type for byte must be unsigned . in fact unsigned is my usage as well . 
|
|
|
|
|
I don't. And anyway, it would mean testing the byte count or position before or after every read which doesn't resolve the issue.
|
|
|
|
|
|
Interesting.
So it still requires a test after each read?
Can it rewind?
|
|
|
|