Skip to content

Instantly share code, notes, and snippets.

View aLucaz's full-sized avatar
🏠
Working from home

Arturo Lucas aLucaz

🏠
Working from home
View GitHub Profile
package main
import (
"fmt"
"log"
"os"
"path/filepath"
"time"
)
def foo(arr):
i = 0
j = len(arr) - 1
while i <= j:
if (arr[i] % 2) != 0:
n = arr.pop(i)
arr.insert(len(arr), n)
else:
n = arr.pop(i)
arr.insert(0, n)
@aLucaz
aLucaz / aug_test.csv
Created June 18, 2021 01:48
Analytics Human Resources
We can make this file beautiful and searchable if this error is corrected: It looks like row 10 should actually have 13 columns, instead of 6 in line 9.
enrollee_id,city,city_development_index,gender,relevent_experience,enrolled_university,education_level,major_discipline,experience,company_size,company_type,last_new_job,training_hours
32403,city_41,0.8270000000000001,Male,Has relevent experience,Full time course,Graduate,STEM,9,<10,,1,21
9858,city_103,0.92,Female,Has relevent experience,no_enrollment,Graduate,STEM,5,,Pvt Ltd,1,98
31806,city_21,0.624,Male,No relevent experience,no_enrollment,High School,,<1,,Pvt Ltd,never,15
27385,city_13,0.8270000000000001,Male,Has relevent experience,no_enrollment,Masters,STEM,11,10/49,Pvt Ltd,1,39
27724,city_103,0.92,Male,Has relevent experience,no_enrollment,Graduate,STEM,>20,10000+,Pvt Ltd,>4,72
217,city_23,0.899,Male,No relevent experience,Part time course,Masters,STEM,10,,,2,12
21465,city_21,0.624,,Has relevent experience,no_enrollment,Graduate,STEM,<1,100-500,Pvt Ltd,1,11
27302,city_160,0.92,Female,Has relevent experience,no_enrollment,Graduate,STEM,>20,,,>4,81
12994,city_173,0.878,Male,Has relevent experience,no_enro
@aLucaz
aLucaz / poc.yaml
Created May 18, 2021 13:46
Cloud Formation Yaml to create private RDS and EC2 connected via tcp
Description:
Goal
-> create a VPC with
-> 1 public subnet
-> 1 private subnet
-> create an Internet Gateway
-> create public instance as bastion
-> create private RDS instance with its inbound rules
Parameters:
@aLucaz
aLucaz / poc.yaml
Created May 17, 2021 14:44
Cloud Formation Yaml to Create Auto Scaled and Load Balanced Architecture
Description:
Goal
-> create a VPC with
-> 1 public subnet
-> 1 private subnet
-> create an Internet Gateway
-> create a Nat Gateway
-> create public instance as bastion
-> create private instance
-> create a load balancer
@aLucaz
aLucaz / poc.yaml
Last active May 13, 2021 15:16
Cloud Formation Yaml to Create Simple Infraestructure
Description:
Goal
-> create a VPC with
-> 1 public subnet
-> 1 private subnet
-> create an Internet Gateway
-> create a Nat Gateway
-> create public instance as bastion
-> create private instance
@aLucaz
aLucaz / aug_train.csv
Last active May 21, 2021 02:23
Analytics Human Resources Dataset
We can't make this file beautiful and searchable because it's too large.
enrollee_id,city,city_development_index,gender,relevent_experience,enrolled_university,education_level,major_discipline,experience,company_size,company_type,last_new_job,training_hours,attrition
8949,city_103,0.92,Male,Has relevent experience,no_enrollment,Graduate,STEM,>20,,,1,36,1.0
29725,city_40,0.7759999999999999,Male,No relevent experience,no_enrollment,Graduate,STEM,15,50-99,Pvt Ltd,>4,47,0.0
11561,city_21,0.624,,No relevent experience,Full time course,Graduate,STEM,5,,,never,83,0.0
33241,city_115,0.789,,No relevent experience,,Graduate,Business Degree,<1,,Pvt Ltd,never,52,1.0
666,city_162,0.767,Male,Has relevent experience,no_enrollment,Masters,STEM,>20,50-99,Funded Startup,4,8,0.0
21651,city_176,0.764,,Has relevent experience,Part time course,Graduate,STEM,11,,,1,24,1.0
28806,city_160,0.92,Male,Has relevent experience,no_enrollment,High School,,5,50-99,Funded Startup,1,24,0.0
402,city_46,0.762,Male,Has relevent experience,no_enrollment,Graduate,STEM,13,<10,Pvt Ltd,>4,18,1.0
27107,city_103,0.92,Male,Ha
#define BUFSIZE1 10
#define BUFSIZE2 13
#define WLOOP 5
#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <sys/wait.h>