From 4a95719d58a708ad55b1389631d6339047f786a0 Mon Sep 17 00:00:00 2001 From: standenboy Date: Fri, 15 Dec 2023 10:19:20 +0000 Subject: added existing work --- comp/work/11/numOfVowles.py | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100755 comp/work/11/numOfVowles.py (limited to 'comp/work/11/numOfVowles.py') diff --git a/comp/work/11/numOfVowles.py b/comp/work/11/numOfVowles.py new file mode 100755 index 0000000..77ab199 --- /dev/null +++ b/comp/work/11/numOfVowles.py @@ -0,0 +1,8 @@ +def count(string): + counter = 0 + for i in string.lower(): + for j in ["a","e","i","o","u"]: + if i == j: + counter = counter + 1 + return counter +print(count("hello")) -- cgit v1.2.3