Message from Python discussions

November 2018

— It will then use the out put of the first return executed in your function

— 

This is my code.. data = get_user_fm(user_id) from above

if data is None:
message.reply_text('Please connect your LastFm account')
if not now_playing:
for i in last_played:
buttons = InlineKeyboardMarkup([[InlineKeyboardButton('YouTube',
url='www.youtube.com/results?search_query=' + str(i.track))]])
message.reply_text(first_name + " was listening to \n" + str(i.track), reply_markup=buttons)
else:
buttons = InlineKeyboardMarkup([[InlineKeyboardButton('YouTube',
url='www.youtube.com/results?search_query=' + str(now_playing))]])
message.reply_text(first_name + " is listening to \n" + str(now_playing), reply_markup=buttons)

— Find the letter

— I still don't know how to do that in a nice looking way

— I could return False but i don't think it makes sense

— I'm a bit confused of what exactly you want, is session.query returning None when there is no data?
if that's the case just use if data is not None: do the rest of the script
the function will return None by itslef if the output of session.query is None

Message permanent page

— If it's returning an error when no data found about user_id u don't even need the None here just use try except

Message permanent page

— ???

— Жəке Елеукенович:
Help me.

Given an integer N and letter C. Print the string of length N containing only C's.

5,A

Message permanent page

— Read the rules

— Knock knock

— If you don’t show some code u tried no one will help, help urself first