Wonderful work getting through the
fmt package’s methods! There are many more methods that we didn’t include, but you can read through Go’s fmt documentation for more in-depth information. Remember, each method is unique in its own way, and it’s up to you to decide what you need to do and which method will help you accomplish that need!
In this lesson we went over:
fmtis pronounced and its purpose.
- The difference between
- How to interpolate strings using
- The verbs:
fmt.Sprintf()will not print strings, but formats them.
fmt.Scan()allows us to take in user input.
If you want to challenge yourself:
- Use another one of fmt’s methods.
- Find out how to interpolate a string that contains an
- Create a program that greets a user and conducts a short conversation.