Chapter 3 Exercise 5 : Python tutorial 56

preview_player
Показать описание
Guys please help this channel to reach 20,000 subscribers. I'll keep uploading quality content for you.

Python is easy programming language to learn and anyone can learn it, and these tutorials are 100% free in hindi.

You can share this playlist with your brother, sisters and friends. This will surely add some values to their life.

If you follow this complete playlist of python tutorial surely you will learn everything about python programming language.

This is exercise 5 of chapter 3

Рекомендации по теме
Комментарии
Автор

name=input("please enter your name: ")
i=0
alpha=0
while i<len(name):
alpha=name.count(name[i])
print(f"{name[i]} times {alpha}")
i+=1

rizwannazeer
Автор

level of task complexity going up, good

FirozBaksh
Автор

name = input("enter name ")
i =0
while i<len(name):
print(f"{name[i]} : {i}")
i +=1

sidhckr
Автор

name=input('enter your name : ')
i=0
while i<len(name):
print(name[i]+" : "+str(name.count(name[i])))
i+=1

dipankur
Автор

name=input("Enter Your Name: ")
i=0
while i<len(name):
count=name.count(name[i])
print(f"{name[i]} --> {count}")
i+=1

sabinpoudel
Автор

name = input("Enter your name please :")
times = 0
i = 0

while i < len(name):
print(name[i], ":", name.count(name[i]))
i += 1

neelusalon
Автор

bhai first attemp me successfull ho gaya. thank you for hint

adityaNON
Автор

Yahoo ... again ur conclusion helped me ...
name = input("Enter your name: ")
length=len(name)
a=0
while a<length:
char=name[a]
if a==0:
print(char+" = ", +name.count(char))
second=char
else:
if char in second:
pass
else:
print(char +" = ", +name.count(char))
second+=char
a+=1

slo_based_study
Автор

# My Code. I am beginner Sir and I did it at first. #Your # are # excellent.
name = input("Enter a word: ")
# name = 'adnan'
i = len(name)
while len(name) != 0:
temp = name[0]
temp_ = (name.count(temp))
temp__ = (name.replace(temp, ""))
name = temp__
print(f"{temp} : {temp_} times")

kanwaradnanrajput
Автор

name = input("writ your name")
n = 0
while n < len(name) :
print(f"{name [n]} : {name.count(name [n])}")
n += 1


I have solved it but I don't know how to prevent alphabets from doubling

mohammadzaidsultan
Автор

name=input("Enter your name ")
i=0
l=len(name)
while 1<l:
c=name.count(name[i])
print(f"{name[i]}:{c}")
i+=1

adityakaushal
Автор

sentense=input("Enter the Sentense:- ")
#sentense.count('e')
lenght=len(sentense)-1
i=0
while i<=lenght:
print(f"{sentense[i]} :-
i=i+1

gauravmarathe
Автор

#Is this correct?
#i got the result but i doubt?
user = input("Enter you name: ")
repeat = input("Enter the letter to check for repeatition: ")
i = 0
b = 0
while i < len(user):
if repeat == user[i]:
b = b + 1
i = i + 1
print("Total: ", b)

samirsubedi
Автор

I did it like this
name= input("enter name: ")
i=0
while i <= len(name)-1:
print(f"{name[i]} count is {name.count(name[i])} ")
a= len(name)
name =name.replace(name[i], "")
b= len(name)
if a==b:

i+=1

abdulhaqmohiuddin
Автор

name = input("enter your name")
i = 0
j = ""
while i < len(name):
if name[i] not in j:
j += name[i]
print (f"{name[i]} : {name.count(name[i])}")
i += 1
i am having problem with this code help me please

firojsiddiquie
Автор

bhaiya apk hisab se abhi kitne lectures or upload ho skte h?

DEEPANSHUAGGARWAL
Автор

Source Code of this Exercise
# Ask a user for the name
# Example = Gaurav
# print count of each word
# output
# G=1
# A=2
# U = 3
# R=4
# A =5
# V=6

# LETS DO THIS

name=input("Please Enter Your name \n")
if name :
i=0
while i<len(name) :
print(name[i] +" = " + str(i))
i=i+1

gauravjha
Автор

#Some different here
#Exercise no5

b=len(us_name)
# print(b)
temp_var=""
a=0
while a<b:

        temp_var+=us_name[a]
        # print(temp_var)
        print(us_name[a], us_name.count(us_name[a]))
    a+=1

learnfun
Автор

Which keys we have to press if it enters into infinite loop

pratikprabhale
Автор

It should be count of each letter not words

amangoel
visit shbcf.ru