I have a List 'SMSStore' which contains a [boolean, string1, string2] eg.
[(False, 'roro', '07189202003'), (False, 'rtptp', '07189202003'), (True, 'rtptp', '07189202003')]
I want to have a function which will loop through the list, check the boolean and return all the string1's of the False booleans.
class SMSMessage(object):
def __init__(self, hasBeenRead, messageText, fromNumber):
self.hasBeenRead = hasBeenRead
self.messageText = messageText
self.fromNumber = fromNumber
hasBeenRead = False
**def get_unread_messages(hasBeenRead):
for i in SMSStore[:][0]:
if hasBeenRead == False:
return messageText**