mirror of
https://github.com/TheAlgorithms/C-Plus-Plus.git
synced 2026-02-11 22:46:39 +08:00
cpp lint fixes
This commit is contained in:
@@ -7,12 +7,13 @@
|
||||
* number that contains 10450 digits!
|
||||
**/
|
||||
|
||||
#include <cinttypes>
|
||||
#include <ctime>
|
||||
#include <iostream>
|
||||
|
||||
#include "large_number.h"
|
||||
#include "./large_number.h"
|
||||
|
||||
large_number fib(unsigned long long n) {
|
||||
large_number fib(uint64_t n) {
|
||||
large_number f0(1);
|
||||
large_number f1(1);
|
||||
|
||||
@@ -26,10 +27,10 @@ large_number fib(unsigned long long n) {
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[]) {
|
||||
unsigned long long N;
|
||||
if (argc == 2)
|
||||
uint64_t N;
|
||||
if (argc == 2) {
|
||||
N = strtoull(argv[1], NULL, 10);
|
||||
else {
|
||||
} else {
|
||||
std::cout << "Enter N: ";
|
||||
std::cin >> N;
|
||||
}
|
||||
@@ -72,4 +73,4 @@ int main(int argc, char *argv[]) {
|
||||
<< std::endl;
|
||||
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
#include <ctime>
|
||||
#include <iostream>
|
||||
|
||||
#include "large_number.h"
|
||||
#include "./large_number.h"
|
||||
|
||||
bool test1() {
|
||||
std::cout << "---- Check 1\t";
|
||||
@@ -72,9 +72,9 @@ bool test2() {
|
||||
int main(int argc, char *argv[]) {
|
||||
int number, i;
|
||||
|
||||
if (argc == 2)
|
||||
if (argc == 2) {
|
||||
number = atoi(argv[1]);
|
||||
else {
|
||||
} else {
|
||||
std::cout << "Enter the value of n(n starts from 0 ): ";
|
||||
std::cin >> number;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user