Python | Split a list having single integer
Given a list containing single integer, the task is to split each value in the list.
Input: Input =  Output: Output = [2, 3] Input: Input =  Output: Output = [1, 5, 4, 7, 8]
Method #1 : Using Map
[2, 0, 0]
Method #2 : Using list comprehension
[2, 3, 1]
Method #3 : Using Loops
[7, 8, 9]
Attention geek! Strengthen your foundations with the Python Programming Foundation Course and learn the basics.
To begin with, your interview preparations Enhance your Data Structures concepts with the Python DS Course. And to begin with your Machine Learning Journey, join the Machine Learning – Basic Level Course