8 kyu
Grasshopper - Check for factor
25,964 of 90,001danleavitt0
Description:
This function should test if the factor
is a factor of base
.
Return true
if it is a factor or false
if it is not.
About factors
Factors are numbers you can multiply together to get another number.
2 and 3 are factors of 6 because: 2 * 3 = 6
- You can find a factor by dividing numbers. If the remainder is 0 then the number is a factor.
- You can use the mod operator (
%
) in most languages to check for a remainder
For example 2 is not a factor of 7 because: 7 % 2 = 1
Note: base
is a non-negative number, factor
is a positive number.
Mathematics
Fundamentals
Similar Kata:
Stats:
Created | Aug 12, 2015 |
Published | Sep 11, 2015 |
Warriors Trained | 117017 |
Total Skips | 8823 |
Total Code Submissions | 141774 |
Total Times Completed | 90001 |
JavaScript Completions | 25964 |
CoffeeScript Completions | 45 |
C# Completions | 3429 |
Racket Completions | 60 |
C++ Completions | 6761 |
Crystal Completions | 32 |
Dart Completions | 1341 |
Elixir Completions | 225 |
Haskell Completions | 430 |
Julia Completions | 91 |
PHP Completions | 1832 |
Python Completions | 21604 |
R Completions | 316 |
Reason Completions | 32 |
Ruby Completions | 1028 |
Factor Completions | 34 |
Java Completions | 6459 |
Elm Completions | 115 |
C Completions | 2178 |
Clojure Completions | 279 |
Go Completions | 3415 |
TypeScript Completions | 1344 |
CFML Completions | 44 |
Solidity Completions | 821 |
VB Completions | 470 |
Rust Completions | 1531 |
Fortran Completions | 90 |
Kotlin Completions | 1940 |
Swift Completions | 2291 |
Nim Completions | 100 |
Lua Completions | 487 |
Objective-C Completions | 89 |
Groovy Completions | 127 |
Scala Completions | 496 |
OCaml Completions | 222 |
PureScript Completions | 40 |
F# Completions | 207 |
Forth Completions | 82 |
PowerShell Completions | 636 |
Shell Completions | 1143 |
SQL Completions | 6506 |
Erlang Completions | 189 |
NASM Completions | 79 |
Prolog Completions | 82 |
COBOL Completions | 29 |
Total Stars | 353 |
% of votes with a positive feedback rating | 90% of 5946 |
Total "Very Satisfied" Votes | 4979 |
Total "Somewhat Satisfied" Votes | 799 |
Total "Not Satisfied" Votes | 168 |
Total Rank Assessments | 186 |
Average Assessed Rank | 7 kyu |
Highest Assessed Rank | 1 kyu |
Lowest Assessed Rank | 8 kyu |