Skip to content

Instantly share code, notes, and snippets.

@lauzi
Created August 26, 2014 14:33
Show Gist options
  • Save lauzi/cf800ee9e5b1e588dc06 to your computer and use it in GitHub Desktop.
Save lauzi/cf800ee9e5b1e588dc06 to your computer and use it in GitHub Desktop.
FUCK C++
struct GG {
int qq[2];
GG (int n=0, int b=0) { qq[0] = n, qq[1] = b; }
};
std::vector<GG> vec;
unsigned pushback(int nxt, int b) {
vec.push_back(GG(nxt, b));
return vec.size()-1;
}
int main() {
pushback(-1, 514);
vec[0].qq[0] = pushback(0, 180); // FUCKING SEGMENTATION ERROR
return 0;
}
@ArcSin2000X
Copy link

good work

@darimuhittin
Copy link

The title made my day.

@evaldasbud
Copy link

no shit idiot

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment