はじめに
デスクトップが汚くなってきたので整理中。
今回のはどこかの記事のコードを書いたやつ。
備忘録コード
test.cpp
#include <iostream>
#include <cmath>
#include <iomanip>
#include <assert.h>
using namespace std;
int main(){
long double n; cin>>n;
//assert(n==0);// n = 0
long double l = 18014415152484098.0 + n;
long double calc = sqrt(l);
cout<< calc <<endl;
long double calc2 = sqrt(18014415152484098.0);
cout << calc2 <<endl;
if(calc == calc2) cout<<"OK"<<endl;
else cout<<"NG"<<endl;
return 0;
}