Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <windows.h> //polskie znaki w terminalu
- using namespace std;
- float liczbanione(float &liczba)
- {
- if (liczba < 5)
- {
- liczba = liczba * 5;
- } else if (liczba > 5)
- {
- liczba = liczba / 5;
- }
- cout << endl << "Podfunkcjone: ";
- return liczba;
- }
- int main()
- {
- SetConsoleOutputCP(65001); //polskie znaki w terminalu
- float liczba;
- cout << "Podaj swoje liczbę: ";
- cin >> liczba;
- cout << liczbanione(liczba);
- cout << endl << "Maino: " << liczba;
- }
Advertisement
Add Comment
Please, Sign In to add comment