First  Prev  1  2  3  4  5  Next  Last
Do you ever get bored?
33 cr points
Send Message: Send PM GB Post
24 / F
Offline
Posted 12/27/15
All the time
5365 cr points
Send Message: Send PM GB Post
27 / M
Offline
Posted 12/27/15
Sometimes I do.
10119 cr points
Send Message: Send PM GB Post
38 / M / USA
Offline
Posted 12/27/15

Radraymond01 wrote:

How to effectively cure boredom.
Step 1: *((char*)NULL) = 0;
Step 2: philosophize why this compiles.


#include <stdio.h>
int main(void)
{
*((char*)NULL) = 0;

// When you expand the NULL macro it looks like this
*((char*) ((void *)0) ) = 0;

// then for example you can do this.
void* x = 0;

// this compiles
*((char *)x) = 0;

// but this does not
(char *)x = 0;

// so your dereferencing
// (a void pointer) (cast as a char pointer). or stated as
// You're setting the value of what x
// is pointing to (while being case as a char pointer) to zero.

// i think

// the real answer is that C/C++ sucks but that's a fight for another day.

}
1232 cr points
Send Message: Send PM GB Post
16 / M
Offline
Posted 12/27/15 , edited 12/27/15

Uncle_Enzo wrote:


Radraymond01 wrote:

How to effectively cure boredom.
Step 1: *((char*)NULL) = 0;
Step 2: philosophize why this compiles.


#include <stdio.h>
int main(void)
{
*((char*)NULL) = 0;

// When you expand the NULL macro it looks like this
*((char*) ((void *)0) ) = 0;

// then for example you can do this.
void* x = 0;

// this compiles
*((char *)x) = 0;

// but this does not
(char *)x = 0;

// so your dereferencing
// (a void pointer) (cast as a char pointer). or stated as
// You're setting the value of what x
// is pointing to (while being case as a char pointer) to zero.

// i think

// the real answer is that C/C++ sucks but that's a fight for another day.

}


I will stab you if you ever diss c++ again.(also, yeah you dereference a null pointer)(undefined behaviour)
10119 cr points
Send Message: Send PM GB Post
38 / M / USA
Offline
Posted 12/27/15

Radraymond01 wrote:


Uncle_Enzo wrote:


Radraymond01 wrote:

How to effectively cure boredom.
Step 1: *((char*)NULL) = 0;
Step 2: philosophize why this compiles.


#include <stdio.h>
int main(void)
{
*((char*)NULL) = 0;

// When you expand the NULL macro it looks like this
*((char*) ((void *)0) ) = 0;

// then for example you can do this.
void* x = 0;

// this compiles
*((char *)x) = 0;

// but this does not
(char *)x = 0;

// so your dereferencing
// (a void pointer) (cast as a char pointer). or stated as
// You're setting the value of what x
// is pointing to (while being case as a char pointer) to zero.

// i think

// the real answer is that C/C++ sucks but that's a fight for another day.

}


I will stab you if you ever diss c++ again.(also, yeah you dereference a null pointer)(undefined behaviour)


Yea, when I was your age I thought it was cool to. How wrong I was,..

1232 cr points
Send Message: Send PM GB Post
16 / M
Offline
Posted 12/27/15

Uncle_Enzo wrote:


Radraymond01 wrote:


Uncle_Enzo wrote:


Radraymond01 wrote:

How to effectively cure boredom.
Step 1: *((char*)NULL) = 0;
Step 2: philosophize why this compiles.


#include <stdio.h>
int main(void)
{
*((char*)NULL) = 0;

// When you expand the NULL macro it looks like this
*((char*) ((void *)0) ) = 0;

// then for example you can do this.
void* x = 0;

// this compiles
*((char *)x) = 0;

// but this does not
(char *)x = 0;

// so your dereferencing
// (a void pointer) (cast as a char pointer). or stated as
// You're setting the value of what x
// is pointing to (while being case as a char pointer) to zero.

// i think

// the real answer is that C/C++ sucks but that's a fight for another day.

}


I will stab you if you ever diss c++ again.(also, yeah you dereference a null pointer)(undefined behaviour)


Yea, when I was your age I thought it was cool to. How wrong I was,..


Make that 10 knives.
10119 cr points
Send Message: Send PM GB Post
38 / M / USA
Offline
Posted 12/27/15

Radraymond01 wrote:


Uncle_Enzo wrote:


Radraymond01 wrote:


Uncle_Enzo wrote:


Radraymond01 wrote:

How to effectively cure boredom.
Step 1: *((char*)NULL) = 0;
Step 2: philosophize why this compiles.


#include <stdio.h>
int main(void)
{
*((char*)NULL) = 0;

// When you expand the NULL macro it looks like this
*((char*) ((void *)0) ) = 0;

// then for example you can do this.
void* x = 0;

// this compiles
*((char *)x) = 0;

// but this does not
(char *)x = 0;

// so your dereferencing
// (a void pointer) (cast as a char pointer). or stated as
// You're setting the value of what x
// is pointing to (while being case as a char pointer) to zero.

// i think

// the real answer is that C/C++ sucks but that's a fight for another day.

}


I will stab you if you ever diss c++ again.(also, yeah you dereference a null pointer)(undefined behaviour)


Yea, when I was your age I thought it was cool to. How wrong I was,..


Make that 10 knives.





4315 cr points
Send Message: Send PM GB Post
23 / M / Arizona
Offline
Posted 12/27/15
I get bored sometimes but usually I find something to do rather quickly.
2519 cr points
Send Message: Send PM GB Post
23 / F / Anime World
Offline
Posted 12/27/15
I am always bored. I either workout, binge on CR, or play on my PS3 all day when I'm at home.
23064 cr points
Send Message: Send PM GB Post
22 / F / Michigan
Offline
Posted 12/27/15
I'm bored 95% of the time, unfortunately. If I knew what to do when I was bored I wouldn't be bored all the time. I usually just putz around on social media and whatnot till I see something that may alleviate my boredom.
9079 cr points
Send Message: Send PM GB Post
21 / M / Everywhere
Offline
Posted 12/27/15
I am made of boredom.
Posted 12/28/15
All the time, ever since I've sold my Xbone and this anime year has been shit so I've been watching the news and doing overtime as well. It's just so ew
5046 cr points
Send Message: Send PM GB Post
19 / M / Ireland
Offline
Posted 12/28/15
Yeah all the time. I used to just watch anime to pass the time but i've watched most stuff worth watching so I just play games now xd
2172 cr points
Send Message: Send PM GB Post
27 / M / Providence, KY
Offline
Posted 12/28/15
Sometimes but when I do I'll either go to sleep or read
1232 cr points
Send Message: Send PM GB Post
M / Chattanooga TN
Offline
Posted 12/28/15
yes..
and I usually post in forums when I do.
First  Prev  1  2  3  4  5  Next  Last
You must be logged in to post.