Guys – Just a little work on attitude. Have fun. Here is what you need to do. We all need to work on our attitude, don’t we?This totally reminded me of the school programming assignments that we use to do (when you do programming 101 kinda subjects). Ok. . . since it reminded me of programming exercise, I did exactly the same.Cheers
- If a = 1%, b = 2%, c = 3%, etcetera, what does ‘attitude’ add up to? ….. (Work it out & see for yourself – ask NO questions just think about it)
#! /usr/bin/python
#
import string
alp=''
for per in range(97,123):
alp = alp + (chr(per))
didisaid = string.lower("attitude")
l = len (didisaid)
total=0
for cal in range(0,l):
c = didisaid[cal]
val = alp.find(c) +1
print c,"=",val
total = total + val
print "total value for :",didisaid," =",total,"%"
No comments:
Post a Comment