This file contains hidden or 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
gitlab: | |
container_name: gitlab | |
image: 'gitlab/gitlab-ee:latest' | |
restart: always | |
# Add your dns name here | |
hostname: 'gitlab.example.com' | |
environment: | |
GITLAB_OMNIBUS_CONFIG: | | |
# Add your dns name here | |
external_url 'http://gitlab.example.com' |
This file contains hidden or 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 <typeinfo> | |
#include <iostream> | |
#include <string> | |
#include <vector> | |
#include <cxxabi.h> | |
struct A{ | |
std::vector<int> a; | |
}; |
This file contains hidden or 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
<?xml version="1.0" encoding="UTF-8"?> | |
<manifest> | |
<remote name="origin" | |
fetch="ssh://addr1" /> | |
<remote name="other-origin" | |
fetch="ssh://addr2" /> | |
<project path="download_path1" name="project_under_remote" remote="other-origin" revision="develop" /> | |
This file contains hidden or 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
void minimumBribes(vector<int> q) { | |
const int maxbribe=2; | |
int step=0; | |
bool invalid=false; | |
int personsize = q.size() - 1; | |
while(true){ | |
bool bribed = false; | |
int bribeCount = 0; | |
This file contains hidden or 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
// Complete the rotLeft function below. | |
vector<int> rotLeft(vector<int> a, int d) { | |
std::vector<int> v; | |
for(int i=0; i<a.size();++i){ | |
v.push_back(a[(i+d)%a.size()]); | |
} | |
return v; | |
} |
This file contains hidden or 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
/* | |
Given a 2D Array, : | |
1 1 1 0 0 0 | |
0 1 0 0 0 0 | |
1 1 1 0 0 0 | |
0 0 0 0 0 0 | |
0 0 0 0 0 0 | |
0 0 0 0 0 0 | |
We define an hourglass in to be a subset of values with indices falling in this pattern in 's graphical representation: |
This file contains hidden or 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
/* | |
I like parentheticals (a lot). | |
"Sometimes (when I nest them (my parentheticals) too much (like this (and this))) they get confusing." | |
Write a function that, given a sentence like the one above, along with the position of an opening parenthesis, finds the corresponding closing parenthesis. | |
Example: if the example string above is input with the number 10 (position of the first parenthesis), the output should be 79 (position of the last parenthesis). | |
*/ |
This file contains hidden or 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 <string> | |
#include <numeric> | |
#include <vector> | |
int main() { | |
std::vector<int> v{1,2,3,4,5,6,7,8,9,10}; | |
auto dash_fold = [](std::string a, int b){ | |
return a+ "-"+ std::to_string(b); |
This file contains hidden or 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 <queue> | |
#include <thread> | |
#include <atomic> | |
#include <string> | |
#include <chrono> | |
int main() { | |
std::queue<int> qth1, qth2; | |
std::thread th1, th2; |
This file contains hidden or 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 <thread> | |
enum COMMAND{CLEAN, FULL_SPEED_AHEAD, EXIT}; | |
int main() { | |
int cmd; | |
bool done=false; |
NewerOlder