Answers for "log in c++"

C++
5

log base c++

int intlog(double base, double x) {
    return (int)(log(x) / log(base));
}
Posted by: Guest on September-14-2020
4

log base e synthax c++

#include <math.h>       /* log */

 double param, result;
  param = 10;
  result = log (param);
  printf ("log(%f) = %f\n", param, result );
Posted by: Guest on June-09-2020
0

log in c++

#include <cmath>
log(number)
Posted by: Guest on June-05-2021
0

how to make a login c++

// a simple login for c++ using while loops and io (input output)
#include <iostream>
#include <string>

using namespace std;

int main() {
  cout << "please enter password";
  string pass = "0";                  // making a string for user input
  cin >> pass;                        // could be replaced with getline(cin, pass);
  while (pass = "1234") {             // while loop for when password is wrong
    cout << "incorrect, try again";
    cin >> pass;                      // could be replaced with getline(cin, pass);
  }
  cout << "correct password";         // runs when the while loop is no longer happening
}
Posted by: Guest on September-28-2020
0

log base 10 c+_+

double log10(double x)
Posted by: Guest on June-11-2020

Browse Popular Code Answers by Language