6 kyu
Zig-Zag Camel
83 of 259dinglemouse
Description:
A camel at the base of a large sand dune wants to get to the top of it to see what is on the other side.
The dune distance d
and height h
are as shown below:
....+ ........| ............| ................| h ....................| ........................| Camel ----------------------------+ d
Steep dunes don't worry him because this is a smart camel!
When the slope is > 30 degrees, then instead of going straight up he will zig-zag back and forth so the climb is not so steep.
Kata Task
Given d
and h
then what is the shortest amount of walking for our smart camel to get to the top of the sand dune?
Mathematics
Puzzles
Geometry
Similar Kata:
Stats:
Created | Nov 16, 2016 |
Published | Nov 20, 2016 |
Warriors Trained | 1341 |
Total Skips | 58 |
Total Code Submissions | 3702 |
Total Times Completed | 259 |
JavaScript Completions | 83 |
Java Completions | 79 |
C# Completions | 36 |
Python Completions | 68 |
TypeScript Completions | 10 |
PHP Completions | 13 |
Kotlin Completions | 11 |
Total Stars | 29 |
% of votes with a positive feedback rating | 92% of 62 |
Total "Very Satisfied" Votes | 53 |
Total "Somewhat Satisfied" Votes | 8 |
Total "Not Satisfied" Votes | 1 |
Total Rank Assessments | 6 |
Average Assessed Rank | 6 kyu |
Highest Assessed Rank | 6 kyu |
Lowest Assessed Rank | 7 kyu |