Skip to content

Instantly share code, notes, and snippets.

View maxchehab's full-sized avatar
🐝
explaining think to sand

Max Chehab maxchehab

🐝
explaining think to sand
View GitHub Profile
<html>
<head>
<title>Porsche Parter</title>
<link rel="shortcut icon" href="./static/genesis_logo.png">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.100.2/css/materialize.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.100.2/js/materialize.min.js"></script>
@maxchehab
maxchehab / rot13.cpp
Created October 3, 2017 00:38
only works for capital letters. Look at an ascii table and modify if statement to make it work for lowercase.
#include <cstring>
#include <iostream>
#include <string>
using namespace std;
char input[80];
int counter = 1;
string sInput;
@maxchehab
maxchehab / volcanoe
Last active September 30, 2017 19:12
process.stdin.resume();
process.stdin.setEncoding('ascii');
var input_stdin = "";
var input_stdin_array = "";
var input_currentline = 0;
process.stdin.on('data', function (data) {
input_stdin += data;
});
@maxchehab
maxchehab / bob
Created September 30, 2017 19:09
process.stdin.resume();
process.stdin.setEncoding('ascii');
var input_stdin = "";
var input_stdin_array = "";
var input_currentline = 0;
process.stdin.on('data', function (data) {
input_stdin += data;
});
#include <iostream>
using namespace std;
int main ()
{
int taxrate;
double costmeal, tiprate;
int totalcost;
cout<<"what is the cost of your meal";
cin>> costmeal;
cout<<" what is the tax rate";
@maxchehab
maxchehab / shopify.php
Last active September 14, 2017 04:47
Shopify backend intern test. Hosted: http://104.236.141.69/shopify/shopify.php
<?php
$data = get_data();
$response = array();
$response["invalid_customers"] = validate($data["validations"], $data["customers"]);
echo json_encode($response);
function validate($rules, $entries){
@maxchehab
maxchehab / fake-language-input.js
Last active September 2, 2017 22:32
Compiler nasm output example
var a = 10;
var b = 15;
var c = a + b;
print(c);
<div class="div-hover">
<!--
href must contain the relative path to the location of the link.
if the link is https://atomic-dev-store.myshopify.com/pages/about-the-bombers-atomic-moto
the relative path is ./pages/about-the-bombers-atomic-moto
-->
<a href="./pages/about-the-bombers-atomic-moto" style="font-size: 35px;">
about us
<img src="https://cdn.shopify.com/s/files/1/1566/3405/t/3/assets/target-150.png">
</a>
tests/autoclassify/test_classify_failures.py::TestFailureDetector
cannot collect test class 'TestFailureDetector' because it has a __init__ constructor
tests/e2e/test_jobs_loaded.py::TestApp
cannot collect test class 'TestApp' because it has a __init__ constructor
tests/log_parser/test_store_failure_lines.py::TestFailureLine
cannot collect test class 'TestFailureLine' because it has a __init__ constructor
tests/model/test_cycle_data.py::TestFailureLine
failure_classifications = None
push_with_three_jobs = <Push: test_treeherder_jobs 45f8637cb9f78f19cb8463ff174e81756805d8cf>
pulse_action_consumer = <kombu.simple.SimpleQueue object at 0x7fbf37a5b610>
test_repository = <Repository: test_treeherder_jobs development>
test_user = <User: testuser1>
def test_resultset_cancel_all(failure_classifications,
push_with_three_jobs, pulse_action_consumer,
test_repository, test_user):
"""