diff --git a/a1/program.c b/a1/program.c index 33ed988..712e79d 100644 --- a/a1/program.c +++ b/a1/program.c @@ -63,8 +63,8 @@ int reading_strings_and_storing_them_in_memory(link* pointer_to_start_of_chain){ } int analizing_string(char* pointer){ float number1, number2, result3; - - + char buffer_for_token[SIZE]; + strcpy(buffer_for_token,pointer); int counter=0; char operant; int i=0; @@ -82,7 +82,7 @@ int analizing_string(char* pointer){ char delim[] =" +=-*/\n"; - char *first_number_cucumber=strtok(pointer, delim); + char *first_number_cucumber=strtok(buffer_for_token, delim); if(first_number_cucumber==NULL||is_number_question_mark(first_number_cucumber)==0){