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
cd ~Path-to-repository | |
git add .; | |
git commit -m"Descriptive message"; | |
git push origin master; |
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 void decideThree() { | |
int slizes = slices.size(); | |
List<Integer>[] adjList = new List[slizes]; | |
for (int i = 0; i < slizes; ++i) { | |
adjList[i] = new ArrayList<>(); | |
} | |
boolean[] done = new boolean[maxPizzas + 1]; | |
done[0] = true; |
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 void decideTwo() { | |
List<Integer>[] adjList = new List[maxPizzas + 1]; | |
for (int i = 0; i <= maxPizzas; ++i) { | |
adjList[i] = new ArrayList<>(); | |
} | |
boolean[] done = new boolean[maxPizzas + 1]; | |
done[0] = true; | |
for (int i = 1; i <= maxPizzas; ++i) { |
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 void decideOne() { | |
int sliz = slices.size(); | |
for (int i = sliz - 1; i >= 0; --i) { | |
if (maxPizzas - slices.get(i) < 0) continue; | |
maxPizzas -= slices.get(i); | |
solution.add(i); | |
} | |
} |
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 void decideOne() { | |
Collections.sort(slices); | |
int sliz = slices.size(); | |
for (int i = sliz - 1; i >= 0; --i) { | |
if (maxPizzas - slices.get(i) < 0) continue; | |
maxPizzas -= slices.get(i); | |
solution.add(i); | |
} | |
} |
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 void parse(String filename) { | |
int bufferSize = 8 * 1024; | |
slices = new ArrayList<>(); | |
BufferedReader bufferedReader = null; | |
try { | |
bufferedReader = new BufferedReader(new FileReader(filename), bufferSize); | |
String line = bufferedReader.readLine(); | |
String[] request = line.split(" "); | |
maxPizzas = Integer.parseInt(request[0]); | |
int pizzas = Integer.parseInt(request[1]); |
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 static void main(String[] args) { | |
String[][] grid = {{"A", "B", "C"}, | |
{"D", "E", "F"}, | |
{"G", "H", "I"}}; | |
for(int row = 0; row < 3; row++) { | |
System.out.println(' '); | |
for(int column = 0; column < 3; column++) { | |
System.out.print(grid[row][column] + " "); | |
} | |
} |
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 <algorithm> | |
#include <vector> | |
#include <queue> | |
using namespace std; | |
int n; | |
int main() { | |
cin >> n; | |
vector<int> graph[1005]; | |
int arr[1005]; |
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 static void main(String[] args) { | |
String[][] grid = | |
{ | |
{"A", "B", "C"}, | |
{"D", "E", "F"}, | |
{"G", "H", "I"} | |
}; | |
} |
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
#!/bin/bash | |
#The script begins with inputing the appScheme , proposed version Number, username and App Specific Password. | |
#The App specific password can be gotten from appleid.apple.com. This can be used in place of your team password. | |
read -p "enter app scheme : `echo $'\n> '`" appScheme | |
read -p "Input new version number format x.y! or retain old version of same format! : `echo $'\n> '`" versionNumber | |
read -p read -p "Enter Username: `echo $'\n> '`" Username |