The calculator program has been completed, and the function is written directly, not written into a class!

xiaoxiao2021-03-05  26

This is a program written with a function, several different functions, solve the input problem!

1, digital input: 0-9, corresponding function: void numberinput (int Num); NUM is the value of 0-9; 2, the decimal point input:., Corresponding function: void pointclick (); 3 |, operator input: =, , -, *, / numbers, corresponding functions: void Operatorinput (int operator); Operator corresponds to 0-5, corresponding to =, , -, *, / five operators. 4, several public variables: BOOL ISPOINTDOWN; / / Decimal point Press the flag, int lastclick; // Type, number, operator, or other string results; // record calculator in the text box; // record calculator Numerical value

Specifically, the next time it is posted!

转载请注明原文地址:https://www.9cbs.com/read-34260.html

New Post(0)