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
def distance(a, b): | |
return (a - b) * (a - b) | |
def full_distance(point_a, point_b): | |
res = 0 | |
for index, value in enumerate(point_a): | |
res += distance(point_b[index], value) |
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 RootUtils { | |
private static Process su; | |
public static void gainRoot() { | |
try { | |
su = Runtime.getRuntime().exec("su"); | |
} catch (IOException e) { | |
e.printStackTrace(); | |
} |
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 <iostream> | |
#include <vector> | |
#include <math.h> | |
#include <iomanip> | |
using namespace std; | |
//4 1 2 3 4 2 1 2 3 3 2 -1 2 4 3 2 1 | |
vector <vector<double>> matrix_inverse(vector <vector<double>> &matr, unsigned int n) { |