#Again, help me with CodeWars.
17 messages · Page 1 of 1 (latest)
My brother in christ, how about you:
- Turn the numbers (spaced) into a list of actual numbers in Python
- Loop through the list keeping track of the smallest element in a variable (if the current one is smaller, set the smallest element to be the current one)
- Return smallest element
where are you learning python from?
str(list(number))
you made number a string?
no no
idk python but looks like transition = number that user input as a string and you used for loop in that list sort it?
and returned i index 0?
take harvard 50
mate gonna save your live
and how did you end up in code war
or whatever that is
I am not sure if you understand the concepts... you should try to follow a course or read a book and try out some exercises
!r python
Here are some resources you may find helpful.
Installing Python
Interacting With Python
Basics Tutorials
Using Real Python
At the bottom of each Real Python article, there are links to the next article that you should probably check out. It's a useful way to continue your learning journey.
I recommend Automate the boring stuff if you are into books. It has exercises and projects to enforce your learning
@ebon topaz You would really benefit from learning how to solve your problems in English first, and then translating English into code. The code you have written indicates you don't really understand what it is doing.
For example, consider the first line:
transition = str(list(number))
In English, this can be said: Convert number to a list, convert the result of that into a string, and then place that value into the variable transition.
All lines of code can be explained in English this way.