-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain - copia.cpp
45 lines (26 loc) · 887 Bytes
/
main - copia.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#include <cstdlib>
#include <iostream>
#include <windows.h>
using namespace std;
int main(int argc, char *argv[])
{
CONSOLE_SCREEN_BUFFER_INFO csbi;
int columns, rows;
GetConsoleScreenBufferInfo(GetStdHandle(STD_OUTPUT_HANDLE), &csbi);
columns = csbi.srWindow.Right - csbi.srWindow.Left + 1;
rows = csbi.srWindow.Bottom - csbi.srWindow.Top + 1;
printf("columns: %d\n", columns);
printf("rows: %d\n", rows);
std::string line;
std::getline(std::cin, line); // read a line from std::cin into line
std::cout << "Your Line Was (" << line << ")\n";
std::getline(std::cin, line);
int x , y;
x=GetSystemMetrics( SM_CXSCREEN );
y=GetSystemMetrics( SM_CYSCREEN );
cout<<"ancho = "<<x<<" x "<<"alto = "<<y;
getchar();
system("PAUSE");
system("cls");
return EXIT_SUCCESS;
}