Skip to content

Instantly share code, notes, and snippets.

#include <iostream>
#include <set>
using namespace std;
#define NUM_ELEM 6
#define NUM_CUTS 32
int elements[NUM_ELEM] = {1, 2, 3, 4, 5, 6};
int possible_cuts[NUM_CUTS][NUM_ELEM-1] = {0};
[
{
"lc_id": 3,
"ip": "",
"gateway": false,
"x": 10,
"y": 20,
"ports": [
{
"status": 1,
while(scanf("%d", &len) != EOF){
}
while(cin >> len){
// finish your code here
}
#include <stdio.h>
int board[8][8];
void print_board() {
int r, c;
for(r=0; r<8; r++) {
for(c=0; c<8; c++) {
#include <Servo.h>
#include <math.h>
int motor_pin[4] = {
3, 5, 6, 9};
Servo motor[4];
int throttle[4] = {
20, 20 ,20 ,20};
#include <dht.h>
#include <string.h>
// define sensor pin
const int water_pin = A0;
const int dht11_pin = 2;
void setup() {
//Initialize serial and wait for port to open:
Serial.begin(9600);
#include <stdio.h>
#include <time.h>
#include <stdlib.h>
int main(int argc, const char *argv[])
{
srand(time(NULL));
int c = 0, a = 0, b = 0;
int num = rand()%5+6;
#include <stdio.h>
#include <time.h>
#include <stdlib.h>
int main(int argc, const char *argv[])
{
srand(time(NULL));
int a = 0, b = 0, c = 0;
int num = rand()%5+6;
int* m[5] = {&a, &a, &b, &c, &c};