Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <Windows.h>
- #include <xkeycheck.h>
- typedef struct money {
- int project, //1 project = 100 kuchmarks
- kuchmark;
- } money;
- typedef struct boosters{
- int num_kafedra;
- } boosters;
- money g_Money = { 0,100 }; boosters g_Boosters = { 0 };
- //Объявление ф-ий
- void CUI(int);
- void feedback();
- /*
- double dtime() {
- double t;
- struct timeval tv;
- gettimeofday(&tv, NULL);
- t = tv.tv_sec + ((double)tv.tv_usec) / 1e6;
- return t;
- }
- */
- //system(cls);
- int main() {
- int hours = 0;
- while (0 < 1) {
- CUI(&hours);
- feedback();
- }
- return 0;
- }
- void CUI(int *hours) {
- system("cls");
- printf("#######################################\n");
- printf("# SIMULYATOR MDKCshnika #\n");
- printf("#######################################\n");
- printf("# project = %2.d | #\n", g_Money.project );
- printf("# kukhmarks = %2.d | #\n", g_Money.project);
- printf("# ---------------- #\n"); //
- printf("# #\n");
- printf("# #\n");
- printf("# #\n");
- printf("# #\n");
- printf("# #\n");
- printf("# #\n");
- printf("# #\n");
- printf("# #\n");
- printf("# #\n");
- printf("# #\n");
- printf("# #\n");
- printf("# #\n");
- printf("# #\n");
- printf("# hours: %2.d #\n", *(hours));
- printf("# #\n");
- printf("#######################################\n\n\n\n\n");
- *hours = *hours + 1;
- Sleep(10);
- }
- void feedback() {
- int a;
- scanf_s("%d", a);
- switch (a) {
- case '1':
- g_Boosters.num_kafedra++;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement