0

How do you use a list in a problem solving? Also array

Which one is better. List or array. What’s the main difference and how they can be use

20th Sep 2018, 4:30 AM
Mark Coching
Mark Coching - avatar
4 odpowiedzi
+ 1
Honestly I've never found a real use for python arrays. For math and datasets I use numpy arrays and for basically every other situation I use a list.
20th Sep 2018, 5:21 AM
JME
0
Generally you should use a list unless you specifically need to use an array. arrays can only store values of the same data type. arrays store data more compactly. math functions can be done directly on an array.
20th Sep 2018, 5:13 AM
JME
0
so array is only good for calculation? what application would be use for? i used the list like ordering food using menu and stuff. i cant give an exmple of an array
20th Sep 2018, 5:16 AM
Mark Coching
Mark Coching - avatar
0
ok thanks for the info.
20th Sep 2018, 5:23 AM
Mark Coching
Mark Coching - avatar