Open
Conversation
semihPy
reviewed
Oct 6, 2021
| #inputs will be in elements list,afterwards we use sort() for sorting list | ||
| elements.sort() | ||
| return('-'.join(elements)) #join() method separates with '-' | ||
| print(sorter()) No newline at end of file |
semihPy
reviewed
Oct 6, 2021
|
|
||
| return(control) #Results will be shown here as same order with given list due to list.append | ||
| print(palindrome_chck()) | ||
|
|
semihPy
reviewed
Oct 6, 2021
| Cap_f_n_=(" ".join(fullname)) | ||
| return(Cap_f_n_) | ||
|
|
||
| print(name_check()) No newline at end of file |
semihPy
reviewed
Oct 6, 2021
| #We use Turkish to make it clear :D | ||
| sayiyazi=onluk[x]+birlik[y] #calling values for each digit to print,adjacent values due to sum str | ||
| return(sayiyazi) | ||
| print(nr_reader()) No newline at end of file |
semihPy
reviewed
Oct 6, 2021
| print("Perfect numbers lower than 1000 :",list(filter(perfect_nr,range(2,1001)))) | ||
|
|
||
| print("Sum of perfect numbers lower than 1000 :",reduce(lambda x,y: x+y,list(filter(perfect_nr,range(2,1001))))) | ||
| # use reduce function to adding all perfect numbers lower than 1000. No newline at end of file |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Revised