The conversation between human and AI assistant.
[|Human|] Rewrite the given code using optimized Algorithm.
[|AI|] The current algorithm used in the code is efficient and optimized for printing numbers from 0 to 9. There is no other more efficient method to achieve the same output as produced by this code using `for` loop in python.
[|Human|] 
Rewrite the given code using optimized Algorithm.