Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

C# C# Basics Strings Combining Strings

Instructor has me pretty lost smh

Program.cs
using System;

class Program
{
    static string eat(string firstFood, string secondFood)
    return 

    // YOUR CODE HERE: Define an Eat method!

    static void Main(string[] args)
    {
        Console.WriteLine(Eat($"I think {firstFood}and{secondFood} are tasty!"));
        Console.WriteLine(Eat($"carrots", "daikon"));
    }

}

1 Answer

The first letter of a method should be a capital letter. When he says that the method needs to return a string, the string needs to be returned from the method. You're are passing the string as an argument to the method, and that's not what we want.