#1
|
|||
|
C appreciation thread
C is what God programmed our universe in. Post your C appreciation, hints, tips, & tricks itt
When Bjarne Stroustrup used to talk about the free-store I always thought new was overloaded to just use malloc. Then I discovered the main difference between new and malloc(): the C function doesn't set up C++ virtual tables so you get a read violation here's a neat trick for detecting big endian system Code:
const union { long one; char little; } is_endian = {1}; if (!is_endian.little) | ||
|
#3
|
|||
|
Cunt
| ||
|
#4
|
|||
|
one little two little three little endians four little fix little six little endians seven little eight little nine little endians
10 little endian boys ps: you dont sound smart using other peoples ideas, thats not computer science thanks bye moron | ||
|
#5
|
|||
|
also in further experimentation just as I suspected malloc() will not implicitly call a constructor/destructor
but who needs C++ when you can just make a few ugly macros, polymorph some typdeffed structs with void pointers, and declare some globals static? also https://www.youtube.com/watch?v=H4YRPdRXKFs | ||
Last edited by r00t; 04-10-2014 at 09:41 AM..
|
|
#6
|
||||
|
Quote:
__________________
Current Games:
Naw | |||
|
#7
|
|||
|
__________________
Tanrin,Rinat,Sprucewaynee | ||
|
#8
|
|||
|
Naw, Fortran!
| ||
|
#9
|
|||
|
| ||
|
#10
|
|||
|
In the solution to the Schrodinger equation for the hydrogen atom, three quantum numbers arise from the space geometry of the solution and a fourth arises from electron spin. No two electrons can have an identical set of quantum numbers according to the Pauli exclusion principle , so the quantum numbers set limits on the number of electrons which can occupy a given state and therefore give insight into the building up of the periodic table of the elements.
look how cool i am! | ||
|
|
|