import numpy as np s1 = [1, 2, 3]s2 = [4, 5, 6]s3 = [7, 8, 9] x = np.array([s1, s2, s3])print(x)print(x[1][2])
Standard input is empty
[[1 2 3] [4 5 6] [7 8 9]] 6
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!