I'm trying to get a list of lists in this format and also separate the name and phone no
[['Jackson, Janet', '313-1352'], ['James, Lebron', '457-6221'], ['Manfredi, Ralph', '872-2221'], ['Prakash, Varun', '312-5398']]
I'm currently getting in this format
['Jackson, Janet 313-1352', 'James, Lebron 457-6221', 'Manfredi, Ralph 872-2221', 'Prakash, Varun 312-5398']
I have been trying these logics
from myDatabasefile import *
b = []
contactlist = select()
print (contactlist)
for row in contactlist:
b.append(row)
print (row)
print(b)