TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Pruthvi Patel
NA
129
23.5k
How to do this type of insert in 2d array in python?
Mar 23 2017 12:56 AM
I have 2D array where y is sorted and unique.so insert operation should be based on y.
x
y
0.012
396.470
0.017
401.480
0.028
406.490
0.032
411.500
0.038
416.510
0.043
421.520
0.046
426.530
0.051
431.540
0.050
436.540
0.050
441.550
and now i have another inputed2darray
0.030
408.505
0.043
421.520
0.050
430.050
0.047
438.540
then output array should be like this
x
y
0.012
396.470
0.017
410.480
0.028
406.490
0.030
408.505
0.032
411.500
0.038
416.510
0.043
421.520
0.046
426.530
0.050
430.050
0.051
431.540
0.050
436.540
0.047
438.540
0.050
441.550
and also return the index of inserted and non inserted(if the element is present in the list then not insert) element
outputindexarr=[3,6,8,11]
yellow highlighted:was not present in the given 2d array so it was inserted in the outputarray
green highlighted: was present in the given 2d array so it was inserted in the outputarray.
Reply
Answers (
0
)
how to create admin account.
Read column wise in csv file using java