Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def SimpleSymbols(s):
- for i in xrange(len(s)):
- if i > 0:
- # If we aren't at the first position, there are valid positions before us
- prev_c = s[i - 1]
- else:
- prev_c = None
- curr_c = s[i]
- if i < len(s) - 1:
- # If we aren't at the last position, there are valid positions after us
- next_c = s[i + 1]
- else:
- next_c = None
- # Now what?
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement