From f2bfdeb28ef6ffd51c4d0a0b39b8b4d78903dadb Mon Sep 17 00:00:00 2001 From: Martin HART Date: Sat, 31 Oct 2020 17:40:53 +0100 Subject: [PATCH] reverse the Instructions vector, so he can behave as a queue --- src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index 3975876..c11d41e 100644 --- a/src/main.rs +++ b/src/main.rs @@ -172,7 +172,7 @@ fn parse_config(conf: String, pool: &mut Vec) -> Result = raw_inst.chars().collect(); + let inst: Vec = raw_inst.chars().rev().collect(); if !robot::is_instructions(&inst) { return Err(String::from("Invalid instructions !")); }