start new:
tmux
start new with session name:
tmux new -s myname
#include <regex> | |
#include <string> | |
#include <vector> | |
std::vector<std::string> Split(const std::string& str, const std::string& regex) | |
{ | |
return {std::sregex_token_iterator(str.begin(), str.end(), std::regex(regex), -1), std::sregex_token_iterator()}; | |
} |
#include <stdio.h> | |
#include <string.h> | |
#include <fcntl.h> | |
#include <errno.h> | |
#include <linux/videodev2.h> | |
int main() { | |
int N = 100; | |
char* deviceName = "/dev/video0"; | |
int fd = open(deviceName, O_RDWR); |
A good commit message looks like this:
Header line: explaining the commit in one line
Body of commit message is a few lines of text, explaining things
in more detail, possibly giving some background about the issue
being fixed, etc etc.
The body of the commit message can be several paragraphs, and
please do proper word-wrap and keep columns shorter than about
#!/bin/bash | |
if [ "$#" != "1" ] | |
then | |
echo wrong number of arguments | |
echo Usage: $0 \<filename\> | |
echo filename - file with build output | |
exit 1 | |
else | |
cat $1 | grep "warning:" | sort | uniq -c | sort -nr | awk '{print $0}{total+=1}END{print "Total number of warnings:\n"total}' |
"""Genetic Algorithmn Implementation | |
see: | |
http://www.obitko.com/tutorials/genetic-algorithms/ga-basic-description.php | |
""" | |
import random | |
class GeneticAlgorithm(object): | |
def __init__(self, genetics): | |
self.genetics = genetics | |
pass |