Update a1/program.c
This commit is contained in:
parent
40686a542a
commit
c7050ddf70
@ -32,10 +32,12 @@ int isMatchingPair(char open, char close) {
|
||||
|
||||
int main() {
|
||||
char code[MAX_LEN];
|
||||
printf("Enter the code: ");
|
||||
fgets(code, MAX_LEN, stdin);
|
||||
|
||||
printf("Read: %s", code);
|
||||
// Убираем лишний символ новой строки, если он есть
|
||||
code[strcspn(code, "\n")] = 0;
|
||||
|
||||
printf("Read: %s\n", code);
|
||||
|
||||
for (int i = 0; i < strlen(code); i++) {
|
||||
char c = code[i];
|
||||
|
Loading…
Reference in New Issue
Block a user