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
| // Related to https://issues.jenkins-ci.org/browse/JENKINS-26481 | |
| abcs = ['a', 'b', 'c'] | |
| node('master') { | |
| stage('Test 1: loop of echo statements') { | |
| echo_all(abcs) | |
| } | |
| stage('Test 2: loop of sh commands') { |
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
| /** | |
| * Example of ZeroMQ pub/sub usage for C++11. | |
| */ | |
| #include <zmqpp/zmqpp.hpp> | |
| #include <iostream> | |
| #include <chrono> | |
| #include <thread> | |
| using namespace std; |
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
| package main | |
| import ( | |
| "bufio" | |
| "fmt" | |
| "log" | |
| "os" | |
| "syscall" | |
| "time" | |
| ) |
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 <stdlib.h> | |
| #include <stdio.h> | |
| #include <fcntl.h> | |
| #include <libtar.h> | |
| int main(int argc, char *argv[]) { | |
| TAR *tar = NULL; | |
| int ret = 0; | |
| int exitcode = 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
| package main | |
| import ( | |
| "os/exec" | |
| ) | |
| func newCmd(imageFile, audioFile, outFile string) *exec.Cmd { | |
| return exec.Command("ffmpeg", | |
| "-r", "1", | |
| "-loop", "1", |
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
| /* AVL Tree Implementation in C++ */ | |
| /* Harish R */ | |
| #include<iostream> | |
| using namespace std; | |
| class BST | |
| { |
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
| (Dijkstra and plain A* are generally not included here as there are thousands of | |
| implementations, though I've made an exception for rare Ruby and Crystal versions, | |
| and for Thor, Mapzen's enhanced A*. ) | |
| A* Ruby https://github.com/georgian-se/shortest-path | |
| A* Crystal https://github.com/petoem/a-star.cr | |
| A* (bidirectional with shortcuts) C++ https://github.com/valhalla/valhalla | |
| NBA* JS https://github.com/anvaka/ngraph.path | |
| NBA* Java https://github.com/coderodde/GraphSearchPal | |
| NBA* Java https://github.com/coderodde/FunkyPathfinding |
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 <stdio.h> | |
| #include <assert.h> | |
| int main(int argc, char** argv) { | |
| assert(argc == 2); | |
| char* fn = argv[1]; | |
| FILE* f = fopen(fn, "r"); | |
| printf("char a[] = {\n"); | |
| unsigned long n = 0; | |
| while(!feof(f)) { |
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
| /** | |
| * Split container into chunks of an equal size | |
| * | |
| * An example C++11 function called chunker that takes | |
| * a container (vector, list, deque), divides it | |
| * into equal chunks of a given size, and returns | |
| * container of chunks. | |
| * | |
| * | |
| * The example code is based on the two following posts: |