AIML Lab Assignment - 4
AIML Lab Assignment - 4
Example:
Message :: “The guy named John is a secret agent”
Encrypted Message :: “vjg"iw{"pcogf"Lqjp"ku"c"ugetgv"cigpv”
Decrypted Message :: “The guy named John is a secret agent”
1) Input : ["Ramesh","Naveen","Rajesh","Alok"]
Output: ['R', 'N', 'R', 'A']
3) Input : ['the', 'quick', 'brown', 'fox', 'jumps', 'over', 'the', 'lazy', 'dog']
Output: [['the', 3], ['quick', 5], ['brown', 5], ['fox', 3], ['jumps', 5], ['over', 4],['the', 3], ['lazy', 4], ['dog', 3]]
3. Write a program to accept some string from the keyboard and display its characters by
index wise(both positive and negative index):
Example:
Input: Hello
Output:
The character present at positive index 0 and at negative index -5 is h
The character present at positive index 1 and at negative index -4 is e
The character present at positive index 2 and at negative index -3 is l
The character present at positive index 3 and at negative index -2 is l
The character present at positive index 4 and at negative index -1 is o
4. Print the given pattern :
Pattern-5:
ABCDEFGHIJ
ABCDEFGHIJ
ABCDEFGHIJ
ABCDEFGHIJ
ABCDEFGHIJ
ABCDEFGHIJ