some tests passed in clock
This commit is contained in:
parent
0ef500d9ef
commit
e63c68efe8
21 changed files with 1181 additions and 0 deletions
7
rust/reverse-string/src/lib.rs
Normal file
7
rust/reverse-string/src/lib.rs
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
pub fn reverse(input: &str) -> String {
|
||||
let mut res = String::new();
|
||||
for ch in input.chars().rev() {
|
||||
res.push(ch);
|
||||
}
|
||||
res
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue