GRACE COE-CSE-GE3171-Problem Solving and Python Programming Laboratory-Ex9c

Published: 04 April 2022
on channel: GRACE COLLEGE OF ENGINEERING
507
2

GRACE COE-CSE-GE3171-Problem Solving and Python Programming Laboratory-Ex9c- Implementing real-time/technical applications for longest word using File Handling
This video shows how to write a python program to implement real-time/technical applications for longest word using File Handling
PROGRAM:
def longest_word(filename):
with open(filename, 'r') as infile:
words = infile.read().split()
max_len = len(max(words, key=len))
return [word for word in words if len(word) == max_len]
print(longest_word('first.txt'))


On this page of the site you can watch the video online GRACE COE-CSE-GE3171-Problem Solving and Python Programming Laboratory-Ex9c with a duration of hours minute second in good quality, which was uploaded by the user GRACE COLLEGE OF ENGINEERING 04 April 2022, share the link with friends and acquaintances, this video has already been watched 507 times on youtube and it was liked by 2 viewers. Enjoy your viewing!