Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 2

!

ZBIR

#include "stdafx.h"
#include <iostream>
const int MAX = 100;
using namespace std;

int main()
{
int a, b,zbir;
printf("U\n");
cin >> a;
printf("\nU2/n");
cin >> b;
zbir = a + b;
printf("Rezultat %d", zbir);
if (a > b)
printf("Veci je a=%d\n", a);
else
printf("Veci je b=%d\n", b);
system("PAUSE");
return 0;
system("PAUSE");
}
2 NAKVECI

#include "stdafx.h"
#include <iostream>
const int MAX = 100;
using namespace std;

int main()
{
int a, b,c,MAX;
printf("U\n");
cin >> a;
printf("\nU2/n");
cin >> b;
printf("C\n");
cin >> c;
MAX = a;
if (MAX < b)
MAX = b;
if (MAX < c)
MAX = c;
printf("Veci je b=%d\n", MAX);
system("PAUSE");
return 0;
system("PAUSE");
}
#include "stdafx.h"
#include <iostream>
#include<string.h>
const int MAX = 100;
using namespace std;

int main()
{
int z;
printf("Ucitaj D/N\n");
cin >> z;
if (z == 0) printf("Ukucano je %d/n",z);
else
if (z == 1) printf("2 Ukucano je %d/n", z);
else printf("3 Ukucano je %d/n", z);
system("pause");
return 0;

You might also like