Skip to content

Instantly share code, notes, and snippets.

View mohanadkaleia's full-sized avatar
🥝

Mohanad Kaleia mohanadkaleia

🥝
View GitHub Profile
[user]
name = Mohanad Kaleia
email = [email protected]
[color]
branch = auto
diff = auto
status = auto
[color "branch"]
current = yellow reverse
local = yellow
[ -f /usr/local/etc/bash_completion ] && . /usr/local/etc/bash_completion
export PS1="\[\033[36m\]\u\[\033[m\]@\[\033[32m\]\h:\[\033[33;1m\]\w\[\033[m\]\$ "
export CLICOLOR=1
export LSCOLORS=ExFxBxDxCxegedabagacad
alias ls='ls -GFh'
source /usr/local/git/contrib/completion/git-completion.bash
GIT_PS1_SHOWDIRTYSTATE=true
# Git branch in prompt.
# app.py
import user as user_service
from flask import request, make_response, jsonify, Flask
app = Flask(__name__)
# server.py
import pika
import config
import tinydb
import json
import user
db = tinydb.TinyDB('db.json')
import random
import pika
import sys
import config
import json
import time
import asyncio
import requests
"""
This implementation for tabu search is modified from:
https://www.techconductor.com/algorithms/python/Search/Tabu_Search.php
Reference:
https://www.researchgate.net/publication/242527226_Tabu_Search_A_Tutorial
"""
import copy
import math
class User {
add(name, age) {
this.name = name;
this.age = age;
console.log(`Username: ${this.name} age: ${this.age}`);
}
add(name) {
this.name = name;
class User {
constructor(name) {
this.name = name;
}
sayHi() {
console.log(`Hi, ${this.name}`);
}
}
let animal = {
eat: true
};
let rabbit = {
jump: true
}
rabbit.__proto__ = animal;
console.log(rabbit.eat); // Here it will print true in the console.
class User {
constructor(name) {
this.name = name;
}
sayHi() {
console.log(`Hi, ${this.name}`);
}
}