6 kyu
Find the odd int
122,853 of 308,822rbuckley
Description:
Given an array of integers, find the one that appears an odd number of times.
There will always be only one integer that appears an odd number of times.
Examples
[7]
should return 7
, because it occurs 1 time (which is odd).[0]
should return 0
, because it occurs 1 time (which is odd).[1,1,2]
should return 2
, because it occurs 1 time (which is odd).[0,1,0,1,0]
should return 0
, because it occurs 3 times (which is odd).[1,2,2,3,3,3,4,3,3,3,2,2,1]
should return 4
, because it appears 1 time (which is odd).
Fundamentals
Similar Kata:
Stats:
Created | Feb 10, 2015 |
Published | Feb 10, 2015 |
Warriors Trained | 541883 |
Total Skips | 61552 |
Total Code Submissions | 826190 |
Total Times Completed | 308822 |
Java Completions | 31790 |
Haskell Completions | 2181 |
JavaScript Completions | 96037 |
Python Completions | 122853 |
Ruby Completions | 9216 |
TypeScript Completions | 5465 |
PHP Completions | 7283 |
C# Completions | 17907 |
F# Completions | 266 |
Clojure Completions | 604 |
NASM Completions | 80 |
CoffeeScript Completions | 44 |
Crystal Completions | 55 |
C++ Completions | 12580 |
Scala Completions | 837 |
Julia Completions | 183 |
Racket Completions | 92 |
Go Completions | 4220 |
Prolog Completions | 40 |
Elixir Completions | 309 |
Pascal Completions | 53 |
Swift Completions | 1103 |
Groovy Completions | 69 |
C Completions | 2741 |
COBOL Completions | 18 |
D Completions | 20 |
Factor Completions | 11 |
Rust Completions | 759 |
Total Stars | 4937 |
% of votes with a positive feedback rating | 90% of 25273 |
Total "Very Satisfied" Votes | 20625 |
Total "Somewhat Satisfied" Votes | 4264 |
Total "Not Satisfied" Votes | 384 |