Skip to content

Instantly share code, notes, and snippets.

@rupython
Created March 6, 2019 08:30
Show Gist options
  • Save rupython/753a7fe7df8b234e4e2addd2e7e01379 to your computer and use it in GitHub Desktop.
Save rupython/753a7fe7df8b234e4e2addd2e7e01379 to your computer and use it in GitHub Desktop.
From: Guzelia
#inputting the information
news_header = input("Введите название для новости: ")
news_text = input("Введите текст новости: ")
news_header = news_header.upper()
text_in_quotes = '"%s"' % news_header
number_of_symbols = len(news_text)
#Outputting the information
print(current_date.rjust(50))
print(text_in_quotes.center(50))
i = 50
format_text = ''
while i <= number_of_symbols:
format_text += format_text + news_text[:i] +' \n ' + news_text[i:]
i+=50
print(format_text)
print("Количество символов в тексте: "+ str(number_of_symbols))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment