

Java Interview Program: How to Separate Zeros from Non-Zeros in an Array? - pramodbablad
http://javaconceptoftheday.com/how-to-separate-zeros-from-non-zeros-in-an-array/

======
jdeisenberg
I never realized that functional programming was changing the way I think
until I saw this problem and wondered how I'd solve it in ClojureScript:

    
    
       (let [numbers [14, 0, 5, 2, 0, 3, 0]
             nonzero (filter (fn[x] (not= x 0)) numbers)]
        (concat nonzero
           (repeat (- (count numbers) (count nonzero)) 0)))
    

I imagine you could do something similar in Java 8 with the removeIf() method
in java.util.Collection

