This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <math.h> | |
double my_cos(double x) { | |
int n = 2; | |
double result = 1; | |
double x2 = x * x; | |
double a = -x * x / 2; | |
while (fabs(a) > 0.0001) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
docker run -d -p 8888:8080 sanitytool/bitreader-service | |
echo "int i = 5;" > test.c | |
clang test.c -c -emit-llvm -femit-all-decls -g -o result.bc | |
curl --header "Content-Type:application/octet-stream" --trace-ascii debugdump.txt --data-binary @result.bc http://localhost:8888/parse |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class BitsInK3 { | |
static int solution(int A[]) { | |
State state = new State(); | |
for (int i : A) { | |
state.putBit(i); | |
state.putBit(i + 1); | |
} |