From 909d254b3d30b2845a1892e2ff66cbee42c9769d Mon Sep 17 00:00:00 2001 From: John H Moore Date: Mon, 22 Jul 2013 12:31:16 -0400 Subject: [PATCH] removed Text/*.py files --- Text/count_vowels.py | 17 ----------------- Text/palindrome.py | 12 ------------ Text/piglatin.py | 22 ---------------------- Text/reverse.py | 8 -------- 4 files changed, 59 deletions(-) delete mode 100644 Text/count_vowels.py delete mode 100644 Text/palindrome.py delete mode 100644 Text/piglatin.py delete mode 100644 Text/reverse.py diff --git a/Text/count_vowels.py b/Text/count_vowels.py deleted file mode 100644 index 847764885..000000000 --- a/Text/count_vowels.py +++ /dev/null @@ -1,17 +0,0 @@ -""" -Count Vowels - Enter a string and the program counts -the number of vowels in the text. For added complexity -have it report a sum of each vowel found. -""" - -string = raw_input('Enter a string: ').lower() - -vowels = ['a', 'e', 'i', 'o', 'u'] -counts = dict(zip(vowels, [0, 0, 0, 0, 0])) - -for vowel in counts: - for char in string: - if vowel == char: - counts[vowel] += 1 - -print counts diff --git a/Text/palindrome.py b/Text/palindrome.py deleted file mode 100644 index 43c7f4145..000000000 --- a/Text/palindrome.py +++ /dev/null @@ -1,12 +0,0 @@ -""" -Check if Palindrome - Checks if the string entered -by the user is a palindrome. That is that it reads -the same forwards as backwards like "racecar" -""" - -string = raw_input('Enter a string: ').lower() - -if string == string[::-1]: - print '%s is a palindrome' % string -else: - print '%s is not a palindrome' % string diff --git a/Text/piglatin.py b/Text/piglatin.py deleted file mode 100644 index 07af62233..000000000 --- a/Text/piglatin.py +++ /dev/null @@ -1,22 +0,0 @@ -""" -Pig Latin - Pig Latin is a game of alterations played -on the English language game. To create the Pig Latin -form of an English word the initial consonant sound is -transposed to the end of the word and an ay is affixed -(Ex.: "banana" would yield anana-bay). Read Wikipedia -for more information on rules. -""" - -word = raw_input('What\'s your word? ').lower() -vowels = 'aeiou' - -pig = 'ay' - -first = word[0] - -if first in vowels: - new = word + pig -else: - new = word[1:] + first + pig - -print new diff --git a/Text/reverse.py b/Text/reverse.py deleted file mode 100644 index eb97aecf3..000000000 --- a/Text/reverse.py +++ /dev/null @@ -1,8 +0,0 @@ -# -*- coding: cp1252 -*- -""" -Reverse a String – Enter a string and the program -will reverse it and print it out. -""" - -string = raw_input("Whatchu wanna say to me? ") -print "You say %s, I say %s" % (string, string[::-1])