Skip to content

Intro to programming, Part 2, Exercise - Number of characters #4

@Jim-Bob-Way

Description

@Jim-Bob-Way

Task asked for "Please write a program which asks the user for a word and then prints out the number of characters, if there was more than one typed in."

during testing i thought it said 3 characters so wrote this code:

input_word = str(input("Please type in a word:"))
letters = len(input_word)
if letters >= 3:
print(f"There are {letters} letters in the word {input_word}")
print("Thank you!")

This passed the testing, yet doesn't actually solve the problem!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions