Skip to content

Hundred Acre Wood

Raymond Chen edited this page Aug 26, 2024 · 6 revisions

Hundred Acre Wood

TIP102 Unit 1 Session 1 Standard (Click for link to problem statements)

U-nderstand

Understand what the interviewer is asking for by using test cases and questions about the problem.

  • Q: What is the function supposed to do?
    • A: The function welcome() is supposed to print the string "Welcome to The Hundred Acre Wood!".
  • Q: Are there any input parameters?
    • A: No, the function does not take any input parameters.
  • Q: What should the function return?
    • A: The function does not return anything; it simply prints a string.

P-lan

Plan the solution with appropriate visualizations and pseudocode.

General Idea: Write a function that prints a predefined string.

1) Define the function `welcome()`.
2) Inside the function, use the `print` statement to output the desired string.

**⚠️ Common Mistakes**

- Forgetting to include the exact string format specified in the problem.
- Adding extra spaces or characters in the string.

I-mplement

Implement the code to solve the algorithm.

def welcome():
    print("Welcome to The Hundred Acre Wood!")
Clone this wiki locally