Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream> // dodawanie bibliotek
- #include <windows.h>
- #include <commctrl.h>
- #include <conio.h>
- using namespace std;
- int main ()
- {
- InitCommonControls(); // różne czary, których i tak nikt nie zrozumie...
- OSVERSIONINFO osvi;
- ZeroMemory( & osvi, sizeof( OSVERSIONINFO ) );
- osvi.dwOSVersionInfoSize = sizeof( OSVERSIONINFO );
- GetVersionEx( & osvi );
- int a = osvi.dwMajorVersion; // główny numer wersji.
- int b = osvi.dwMinorVersion; // pomniejszy numer wersji.
- cout << "wersja " << a << "." << b << endl; // wyświetlenie.
- getch (); // oczekuje na naciśnięcie dowolnego przycisku.
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement