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 trialBenjamin Lim
2,747 PointsWhen did we ever learn to add external names to parameters? I'm flipping through my notes and cannot find it?
Am I forgetting something? It's asking me to add an external name to the parameter? Is this something that we've been taught so far or are we expect to figure it out for ourselves?
// Enter your code below
func getRemainder(a: Int, b: Int) -> Int {
return a % b
}
2 Answers
Jason Anders
Treehouse Moderator 145,860 PointsHey Benjamin,
Pasan coves local and external parameter names in the video right before this challenge. He starts right at the beginning and shows how to create an external parameter name at the ~1:30 mark in the video.
Hope this helps.
Angel Caro
11,831 PointsYou add external parameters before the parameter like value for a and divisor for b like so:
func getRemainder(value a: Int, divisor b: Int) -> Int {
return a % b
}