diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2017-11-22 16:09:50 +0900 |
|---|---|---|
| committer | Yukihiro "Matz" Matsumoto <[email protected]> | 2017-11-22 16:09:50 +0900 |
| commit | b4f9b031deaf7c75dad7aa10f2318bb37e268fa3 (patch) | |
| tree | 6e38cc9b61330d34d09e157bca406dc1b084198c /benchmark/bm_so_lists.rb | |
| parent | 284a1d12ee6b0fdd77b042771f5db833112fc14e (diff) | |
| download | mruby-b4f9b031deaf7c75dad7aa10f2318bb37e268fa3.tar.gz mruby-b4f9b031deaf7c75dad7aa10f2318bb37e268fa3.zip | |
Some cosmetic changes
Diffstat (limited to 'benchmark/bm_so_lists.rb')
| -rw-r--r-- | benchmark/bm_so_lists.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/benchmark/bm_so_lists.rb b/benchmark/bm_so_lists.rb index e8f4a2a5f..512e312cc 100644 --- a/benchmark/bm_so_lists.rb +++ b/benchmark/bm_so_lists.rb @@ -17,19 +17,19 @@ def test_lists() # li2 must now be empty # remove each individual item from right side of li3 and # append to right side of li2 (reversing list) - while (not li3.empty?) + until li3.empty? li2.push(li3.pop) end # li3 must now be empty # reverse li1 in place li1.reverse! # check that first item is now SIZE - if li1[0] != SIZE then + if li1[0] != SIZE p "not SIZE" 0 else # compare li1 and li2 for equality - if li1 != li2 then + if li1 != li2 return(0) else # return the length of the list |
