8 kyu

Find Multiples of a Number

18,809 of 49,669Spherixo

Description:

In this simple exercise, you will write a function that takes two integers; n and limit; and returns a list of the multiples of n up to and possibly including limit.

It is guaranteed that n > 0 and limit >= n.

For example, if the parameters passed are (2, 6), the function should return [2, 4, 6] as 2, 4, and 6 are the multiples of 2 up to 6.

Examples

n = 2; limit = 6 --> [2, 4, 6]
n = 2; limit = 5 --> [2, 4]
Fundamentals
Arrays

Stats:

CreatedMar 16, 2017
PublishedMar 16, 2017
Warriors Trained76013
Total Skips4574
Total Code Submissions118460
Total Times Completed49669
Python Completions18809
Ruby Completions1017
JavaScript Completions22461
Crystal Completions43
C# Completions2340
Rust Completions1076
TypeScript Completions976
C Completions534
Factor Completions15
Go Completions1645
D Completions21
Lua Completions208
OCaml Completions118
Scala Completions117
Haskell Completions198
CoffeeScript Completions16
PHP Completions531
COBOL Completions12
Java Completions1192
Total Stars500
% of votes with a positive feedback rating93% of 4275
Total "Very Satisfied" Votes3726
Total "Somewhat Satisfied" Votes491
Total "Not Satisfied" Votes58
Total Rank Assessments12
Average Assessed Rank
7 kyu
Highest Assessed Rank
7 kyu
Lowest Assessed Rank
8 kyu
Ad
Contributors
  • Spherixo Avatar
  • jhoffner Avatar
  • asmgf Avatar
  • GiacomoSorbi Avatar
  • Chrono79 Avatar
  • imjasonmiller Avatar
  • JohanWiltink Avatar
  • mmalkavian Avatar
  • Souzooka Avatar
  • My- Avatar
  • KiparD Avatar
  • monadius Avatar
  • hobovsky Avatar
  • trashy_incel Avatar
  • kirull Avatar
  • ejini战神 Avatar
  • akar-0 Avatar
  • Kacarott Avatar
  • tri@ Avatar
  • dfhwze Avatar
  • Glinator Avatar
  • Gauntlet9868 Avatar
  • fcr-- Avatar
  • KayleighWasTaken Avatar
  • LosBlobbos Avatar
Ad