« first day (261 days earlier)      last day (4687 days later) » 

5:01 PM
Yeah, that's how it should be done IMO. Many teachers try to cover up in situations like that
 
Thank god I never had one of those.
 
sbi
@hexa What helped in my situation was that I wasn't a professor attempting to teach programming, but a programmer, doing teaching as the one of many possible side-projects I had the most fun in. I didn't just tell them Never Do X, I told them how much overtimes we once had to put in in a company where we did X, and it backfired badly.
I have been programming for a living now for >15 years, and I have seen my share of fuck-ups. Sharing this experience as graphically as possible is the best you can give to your students, because it prevents them from having to learn this by fucking up for themselves.
 
Xeo
5:17 PM
@sbi, mind teaching me? :)
 
sbi
@Xeo As I said, I only taught C++, and I doubt I could teach you much about that. :)
 
Xeo
Oh, I don't doubt that. I don't know much of real life C++, aka C++ applied for real work.
Only our semester game projects
 
oh hai guise
 
Weren't you here like, half an hour ago?
Or hour.
I need Sleep(43200000).
 
5:27 PM
did you derive that number from a specific formula?
 
Why yes, it's called multiplication.
:P
 
any specific values?
 
Xeo
12 * 60 * 60 * 1000 ?
 
12 hours.
 
@CatPlusPlus Humans usually sleep about 8 hours a day.
 
5:28 PM
@MartinhoFernandes I usually sleep around 12 hours.
 
8-10 hours
 
Xeo
@MartinhoFernandes I usually sleep around 14 hours.
 
and more at certain life cycle stages
especially young adults take a lot more sleep
 
Xeo
Sometimes, like the day before yesterday even 24 hours
 
I slept about 18h on I think Saturday.
Or maybe it was already Sunday.
Hard to keep track of those days.
 
Xeo
5:29 PM
Oh, I even slept 20 hours today!
@CatPlusPlus Come again in the holidays. I totally lose my sense of time there.
"Huh, what, school?" - "Yeah, it started 2 days ago."
 
yeah, me too
I usually end up sleeping in the day and working in the night
and by "working" I mean, well, not doing anything of any use to anyone, ever
 
Xeo
Isn't that the purpose of a student?
 
lol
 
Xeo
@ÓlafurWaage Rather, hide your catweed @Cat!
 
I mostly played Fallout: NV recently.
 
Xeo
5:33 PM
Isn't that horribly bugged beyond help?
 
You're just a wunch of bankers then?
 
It is somewhat bugged, but I haven't had any problems that would render it unplayable. It froze a few times on loading, crashed once or twice, and has some scripting errors they still haven't fixed. But overall, it's great.
I guess it was much worse on launch.
It's on today's Steam sale list.
For 15€.
 
I stopped with WoW after 4 years, now I can get back to learning new stuff, like C++
MMOs are the devil.
 
I just found them too repetitive
I'm a creation guy now, I create things, in WoW you just raid the same content over and over and over again
 
I've always been a creation guy and I played wow for the reason i was not creating anything but a full epic'd char. then another one, over and over again
 
5:40 PM
@DeadMG You might like Minecraft. :P
 
@CatPlusPlus: Nope
 
I never understood that game and why it is so fun, really
 
the time from idea to inception is way too long
 
It must be, since it is highly popular, but i just don't get it
 
Mining, exploring, building, building, building, creepers.
 
5:42 PM
even on that free mode where you can spawn infinite blocks
 
Well, it wouldn't be fun if it were effortless.
2
 
I find it extremely depressing to spend hours building something you would have done in minutes with an editor.
 
fun is what you've created, not how you created it
 
Depends on the taste, I guess. For me, creating in editor would be boring (oh, click, click, click, bleh).
 
then obviously you're not creating something interesting enough
 
5:44 PM
You can get Blender and make whatever you want, no need for a game there.
 
I didn't said that would be better. I play minecraft too, but this idea still kind of makes me sad.
 
Xeo
I like Rollercoaster Tycoon. A game and an editor at the same time!
 
Also exploring is cool.
 
@CatPlusPlus: I wouldn't mind that at all. Blender's interface is kind of slow though and I'm not that hot into art, I prefer programs
 
And the next update is adventuring one.
 
5:47 PM
@DeadMG programming is also kind of an art :)
 
@kbok: Yeah, I feel that way too. I meant art as in models :P
 
my code will remind you of picasso, it's that good!
 
Xeo
Now I got the feeling of never wanting to see your code.
 
perhaps i'll be famous after my death
 
Is it all arranged in circles, triangles and squares?
(Or am I confusing crazy people here?)
 
5:55 PM
it will invoke a broad range of emotions
 
Like crying and cursing?
 
it depends on who looks at it, it reflects your inner being
 
I think I'll go to sleep now, I'm supposed to be working in the morning. G'bye.
 
night
@Xeo In real-life situations the non-language specific rules are very important: modularity, "weak coupling and strong cohesion", and so on.
 
Has anyone read this book? Would you recommend it or is it too out of date?
 
6:03 PM
> Calculator Pro X Eliminates archaic functions like multiplication and division. Face it, addition is what you do 99% of the time anyway. Much faster this way.
 
@MartinhoFernandes is it possible to calculate the square root of two using only addition?
 
I think so.
Incredibly slow, but possible.
Multiplication is iterated addition.
Integral division is iterated subtraction.
 
I've heard all operations can be reduced to addition. But I never learned how. I wouldn't know how to calculate 5/3 using additions.
 
it's a complex math subject @StackedCrooked
its called Series. There are many type of series and they are all annoying
 
I think Neighbours is an annoying series.
 
6:09 PM
sin and cosin can be reduced to sums of divisions to arbitrary precision
 
@hexa Isn't that numeric algebra? I've seen some of that.
 
sure, in the end it is
the problem is how to make those simple algebra equations
 
@StackedCrooked Not all operations. You can't do the symmetric operation with only addition.
 
What is the symmetric operation again?
 
You probably know it as the unary minus operator.
 
6:11 PM
Ah
 
But armed with the addition and the symmetric operations, you can do lots o' stuff.
Because subtraction is just addition with the symmetric.
And there, you've got all four basic arithmetic operations. You're bootstrapped.
 
I still don't know how to do division!
 
Do you remember the division algorithm from elementary school?
You can use that one, as it uses only addition, subtraction and multiplication.
Or you can do integral division with repeated subtractions.
Say: 13/2. 13 - 2 = 11. 11 - 2 = 9. 9 - 2 = 7. 7 - 2 = 5. 5 - 2 = 3. 3 - 2 = 1. We did 6 subtractions. The quotient is 6, and the remainder is 1.
 
@MartinhoFernandes Honestly, I forgot how to do it.
Cool.
Indeed, it works.
 
In college i learned an ARCANE method to do hardware multiplication and division
it was so weird and it worked
it was a series of shifts and OR's and AND's and it involved a small lookup table
but you had a fixed number of iterations
 
6:21 PM
What if it is true? abstrusegoose.com/376
We might be doing a terrible mistake.
(don't forget to scroll down)
 
7:02 PM
I'm slightly drunk. From two beer.
(beers?)
 
bears
two bears
 
Today I learned how to do OOP in JavaScript. Oh. My. God. Everything is so incredibly dynamic!
You can add and remove data and methods at runtime!
C++ and JavaScript share a terrible "feature": they have no modules.
 
7:20 PM
Want to ask a question to all stackers here
 
Xeo
Ugh, "stackers". Please, just call us "coder"
 
ok grins
 
oh shit, sorry man
I changed the focus on my windows wrong and the chat window vanished
 
no problem
can you join it again please>
 
I'm still in the room
 
7:23 PM
then can you answer in my situation in that?
 
hi
I have a question regarding tic tac toe
well i mean tic tac toe
particularly min/mac
min/max
 
Seems like everyone has a question today.
But no one wants to share it.
Selfish, that's what you are.
 
I have a question, and I dare you to guess it.
 
Is it "Can he guess it?"
lol
 
Xeo
7:43 PM
I just found this goodie, if you're not pleased with your current employer:
> Change your team or change your team -- Andy Hunt
 
@DeadMG Is it actually bad ettiquite to evedrop? Or generally join midway into a conversation
 
Is delphi still used? Or Object Pascal in general? Or is it fading away?
I hardly see any questions in SO about delphi
 
I bet every language that you have ever heard of is still being used.
 
@FredOverflow even Ook?
 
I have never heard of Ook. Do you mean Oak, a.k.a. Java? That is still being used heavily.
Is it true that Java was originally going to be called C++++?
 
7:49 PM
nah
 
That seems like a misnomer.
C++-- would be a better fit for Java.
 
lol
 
I meant Ook. Its a very silly language
 
Brainfuck for Orang-Utans? WTF?
 
Yes that
 
7:56 PM
Whats wrong with people writing BrainF programs, it's so... I don't even know
 
Works with any language you don't like, btw
 
hum
DECSS
there is a brainfuck compiler as well
 
I need an avatar
 
@FredOverflow I think :( would a better name for Java.
 
8:08 PM
or LuLz
 
WinePlusWater would also work.
 
@StackedCrooked In Belgium at what temperature you start saying "its cold"?
 
@hexa Depends on the season. I think in summer less than 15 degrees would be considered cold.
20+ degrees are desireable
but 26+ is considered too hot by most.
 
In most parts of Brazil, Winter temperature is between 5 and 15 celsius. We almost never get below zero
today is cold, it is prolly around 13 degrees, makes typing terrible
 
Only 13 degrees in Brazil in July? That's surprising.
I thought it was tropical there :)
Looking at the weather forecasts for San Paolo right now and yes, today 13 degrees max. Is this normal?
 
8:16 PM
@Raynos: It's about function. The function of the room was for me and M3taSpl0it to chat. There are other rooms that have the function for you to chat in them, so use them for that purpose.
 
@StackedCrooked It is winter so yeah, it is for this time of the year
 
I forgot Brazil was on the southern hemisphere. I suck :(
 
8:30 PM
@DeadMG Yeah, I guess so. It's not the place.
Although I am curious whether people prefer opengl or direct3d in general.
 
user379888
Hi
 
user379888
I am upto reading and writing from the same file while it is opened. I am having problem with what should be the condition to find the End Of File as there will be EOF placed in it.
 
@JustAnotherProgrammer stackoverflow.com/questions/21647/… does this answer your question?
 
user379888
8:45 PM
@hexa: not really
 
user379888
There won't be any EOF in my case
 
user379888
Isn't EOF character placed just before the file is closed?
 
No
 
There's no EOF character written at the end of files.
 
user379888
@MartinhoFernandes: Can you explain it a bit?
 
8:48 PM
EOF is not a character. It's just the "end of file". A file on disk does not have a terminating character.
 
@MartinhoFernandes you are a linux user, right?
 
Say, if you write "123456789" to a file, it will only contain those 9 characters. There won't be a tenth character to mark the end.
@hexa ATM yes.
 
user379888
@MartinhoFernandes: EOF has a value="-1" in many systems
 
user379888
This is from Wikipedia:en.wikipedia.org/wiki/End-of-file
 
@JustAnotherProgrammer cplusplus.com/reference/iostream/ios/eof does this help you understand the concept?
 
8:51 PM
@JustAnotherProgrammer No. That's what some reading functions return when they reach the end of file. There is no such character.
 
@MartinhoFernandes So, in linux, i am used to do, for example man 3 printf and get a nice reference on the function in question. Is there such a command for C++?
 
@hexa I don't think there are manpages for the C++ standard library. It would be nice, though.
 
user379888
@hexa: No :(
@MartinhoFernandes:From Wikipedia,In the C Standard Library, the character reading functions such as getchar return a value equal to the symbolic value (macro) EOF to indicate that an end-of-file condition has occurred. The actual value of EOF is system-dependent (but is commonly -1, such as in glibc[1])
 
Whats the go-to reference then? People often curse cplusplus.com
 
@hexa cplusplus.com has some errors in it. It's not bad if you already know your C++ and are trying to remember something. But don't treat everything in it as authoritative.
 
user379888
8:54 PM
@hexa: My problem is different. I know about EOF but my program keeps on reading from the file even after the end
 
user379888
Wait I will just post it on SO
 
@JustAnotherProgrammer your problem doesn't seem to be different. Please check the ::eof method.
 
@JustAnotherProgrammer Just like I said. getchar returns -1 when you reach the end of file. But there is no "EOF character" to be written.
That quote you posted actually continues with "and is unequal to any valid character code."
 
user379888
@hexa:
do
{
cout << file.read((char *)(pRecord[i]),sizeof(Record));
}while(!file.eof( ));
 
that seems to be ok, i can't be sure tho. If you want proper answers you really should ask at stackoverflow.com
 
8:57 PM
The preferred way to read until the end of file in C++ is while(stream) /* read */;.
 
user379888
@MartinhoFernandes: I have never heard of it . Wait let me Google it :)
 
to get a nice tag with an icon in SO, you need to pay, right?
 

« first day (261 days earlier)      last day (4687 days later) »