All pastes #115816 Raw Edit

Stuff

public cpp v1 · immutable
·published 2006-08-04 21:12 UTC
rendered paste body
 int nRiktigeSvar = 0; string svar;cout << "Text"; cin >> svar; if (svar == "1") { nRiktigeSvar = +33; } if (svar == "2) { nRiktigeSvar = +0; } cout << "text"; cin >> svar;  if (svar == "1") { nRiktigeSvar = +11; } if (svar == "2) { nRiktigeSvar = +1; }cout << nRiktigeSvar;// Shouldnt this print 44 (if svar = 1)? Why doesnt it? And how can I add more to nRikitigeSvar without the previous number gets deleted?