мясной снек KABANOS
p1ke   Alta, Finnmark, Norway
 
 
#include "stdafx.h"
#include <iostream>

using namespace std;

class cache
{
int rub;
int cop;
public:
void setmoney (int x, int y) { rub = x; cop = y;};
void loan(cache x)
{
rub = rub + x.rub;
cop = cop + x.cop;
rub = rub + cop / 100;
cop = cop % 100;
}
void show()
{
if (rub < 0)
{
cout << "DOLG!!! - " << rub << " RUB " << cop << " COP " << endl;
}
else if (rub > 0)
{
cout << "BALANCE - " << rub << " RUB " << cop << " COP " << endl;
}
}

void spend(int x, int y)
{
rub = rub - 1 - x;
cop = cop + 100 - y;
rub = rub + cop / 100;
cop = cop % 100;

}
}mycard;


int main ()
{
mycard.setmoney(500000, 45);
cache stup;
stup.setmoney(200, 99);
mycard.show();
mycard.loan(stup);
mycard.show();
mycard.spend(5000, 1);
mycard.show();
Currently Offline
Recent Activity
59 hrs on record
last played on 27 Dec
32 hrs on record
last played on 21 Dec
83 hrs on record
last played on 5 Nov
Comments
Helky >.< 11 Nov, 2022 @ 10:18am 
/”.\_|_|_____|_|__________/\_____ __________
|::::::::::::______---………[___]________________|+REP+REP+REP+REP+REP +RIP
|::::::_-“”””””)__/(_(_)|_______.-“"""""""""""
|_,.-“. . . . . /--./. . . . . . . .\___\
. . . . . . . . /__/. . . . . . . . . \___\ <---магазин +REP