Skip to content

Instantly share code, notes, and snippets.

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

Owanate Amachree owans

🏠
Working from home
View GitHub Profile
@owans
owans / timeoff_db.md
Last active April 16, 2019 21:38
A workbench image of relationship description for the timeoff_app database

Entities:

Employee Organiation Manager Timeoff_type

Entities and data_types employee_table: id(INT), employee_id(VARCHAR), first_name(VARCHAR), last_name(VARCHAR), gender(VARCHAR), DOB(DATE), LGA(VARCHAR), state_of_origin(VARCHAR), phone_nos(VARCHAR).

@owans
owans / tomorrow.js
Last active April 17, 2019 17:27
API for tomorrow's weather
const ora = require('ora');
const getWeather = require('../utils/weatherforecast');
const getLocation = require('../utils/location');
module.exports = async (args) => {
const spinner = ora().start();
try{
const location = args.location || args.l ||await getLocation();
@owans
owans / HashTable.md
Last active April 8, 2019 18:53
Find duplicate nos in array using hash tables

//hash tables are used to iterate over an array using a key to compute the array index, instead of using the key as an array index

//for this function i is used as a key to loop through the array

const showDuplicateNo = (array) => { let hashTable = []; let duplicateNo = [];

for (let i = 0; i < array.length; i++) {

@owans
owans / owansLogistics.md
Last active April 2, 2019 21:35
LevelUp Coding Challenge: Design a database for a Logistics Company

Identify Entities

a. Warehousing

b. Shipping

c. Inventory

d. Security