FIXED: clearing inputs bug
This commit is contained in:
@@ -36,7 +36,10 @@ pub fn processing_input(input: &String) -> String {
|
||||
}
|
||||
|
||||
pub fn check_correct_input(input: &String, prepared_input: &String, l: usize) -> (bool, bool) {
|
||||
let first_condition = input.chars().all(|c| c == '1' || c == '0' || c == ' ');
|
||||
let first_condition = input
|
||||
.as_str()
|
||||
.chars()
|
||||
.all(|c| c == '1' || c == '0' || c == ' ');
|
||||
|
||||
let second_condition = prepared_input.len() % l == 0;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user