Join Todd McLeod for an in-depth discussion in this video Refining our permutations algorithm, part of Code Clinic: Go.
- So we're now going to refine our permutation algorithm.…And we were just looking at this first file right here.…We created a bunch of permutations with nested loops.…And let me just bring that file up.…So it's 01, and then go run main.go.…The challenge that I posed is…find all the permutations of A B C.…So the question I have is,…"Are these all valid permutations?"…And remember, again, the challenge for us…was to find all of the permutations of A B C.…So I'm asking, "Are these all valid permutations?"…And I'll give you a hint.…
The answer is no.…But why?…Why are they all not valid permutations?…The reason is because some of them…are using the same letter twice.…So B B, B B B, A C A,…and we only have one A.…We only have one B.…We only have one C.…So only things where each letter is unique are valid.…And we now need to refine our permutation algorithm…to just give us the valid results.…And to do that, I did a little filter.…And the filter I did here was this line right there.…And let me just show you how it does filter it out.…
Todd introduces challenges and then provides overviews of his solutions in Go. Challenges include topics such as statistical analysis, searching directories for images, and accessing peripheral devices.
Skill Level Beginner
Google App Engine Essential Trainingwith Joseph Lowery3h 26m Intermediate
1. Problem 1—Exploring Lake Pend Oreille
2. Problem 2—Image Analysis
3. Problem 3—Eight Queens
4. Problem 4—Accessing Peripherals
5. Problem 5—Recursion and Directories
6. Problem 6—Building the Web
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.