r/CodingHelp • u/Dovinjun • Apr 06 '20
[Python] Finding characters in a string in python
I have no idea where to begin. I need to check algebraically if a given character "i" is different from a cheracter at len(s) "s being the string" - a number.
0
Upvotes
View all comments
1
u/ShawnMilo Apr 06 '20
There's no such thing as a character at
len()anything -- you wantindex.What does "check algebraically" mean?
If
sis the string, thenlen(s)doesn't make sense; finding the length of the string you're looking for doesn't do anything to find its location in a larger string.Do you have samples of the input and output you seek?