forked from ChicoState/cpp-gtest
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrando.cpp
More file actions
44 lines (35 loc) · 813 Bytes
/
rando.cpp
File metadata and controls
44 lines (35 loc) · 813 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
//Author: Kevin Buffardi
#include "rando.h"
#include <string>
/**
* Determines if either first or second parameter is evenly
* divisible by the other.
**/
bool Rando::isDivisibleBy(int first, int second)
{
return true;
}
/**
* Determines, without case sensitivity, whether the parameter is
* if read either backwards (right-to-left) or forwards (left-to-right)
**/
bool Rando::isPalindrome(std::string eval)
{
return true;
}
/**
* Returns the digit {0...9} that occurs the most often within the parameter
* or returns -1 if there is no single digit that occurs more often than all
* the others
**/
/*
* take into consideration what is input?
* what is the expected value?
*/
unsigned int Rando::mostPopularDigit(unsigned int num)
{
int most;
int popular;
popular = num%10;
return popular;
}