Skip to content

Instantly share code, notes, and snippets.

Challenge

-------------------------------------------

our client is an online marketplace, here is a sample of some of the products available on our site:

Product code  | Name                   | Price
----------------------------------------------------------
001 | Lavender heart | £9.25
Our marketing team have added another promotions as an incentive for our customers to purchase these items.
If you buy 3 Kids T-shirt then the third one is free.
Test data
---------
Basket: 003, 003
Total price expected: £39.90
@alexfilatov
alexfilatov / shopifystores.csv
Created February 25, 2019 17:08
List of ~10k Shopify Stores
We can make this file beautiful and searchable if this error is corrected: No commas found in this CSV file in line 0.
Store
https://jeffsmith.myshopify.com
https://kimmo.myshopify.com
https://dorkbot.myshopify.com
https://jeffsmith.myshopify.com
https://kimmo.myshopify.com
https://dorkbot.myshopify.com
https://mp3player.myshopify.com
https://tiner.myshopify.com
https://pict.myshopify.com
@alexfilatov
alexfilatov / Transformer.ex
Created August 6, 2018 21:00 — forked from trojanh/Transformer.ex
Create Image thumbnail using ImageMagick in Elixir
defmodule Image.Transformer do
def transform(original_file, operation \\ "convert") do
thumb_path = generate_thumb_file(original_file)
System.cmd(operation, operation_commands(original_file_path, thumb_path))
thumb_path
end
defp generate_thumb_file(original_file) do
@alexfilatov
alexfilatov / US Zip Codes from 2013 Government Data
Created May 12, 2018 12:41 — forked from erichurst/US Zip Codes from 2013 Government Data
All US zip codes with their corresponding latitude and longitude coordinates. Comma delimited for your database goodness. Source: http://www.census.gov/geo/maps-data/data/gazetteer.html
This file has been truncated, but you can view the full file.
ZIP,LAT,LNG
00601,18.180555, -66.749961
00602,18.361945, -67.175597
00603,18.455183, -67.119887
00606,18.158345, -66.932911
00610,18.295366, -67.125135
00612,18.402253, -66.711397
00616,18.420412, -66.671979
00617,18.445147, -66.559696
@alexfilatov
alexfilatov / 10000-MTV-Music-Artists-page-1.csv
Created March 7, 2018 15:25 — forked from mbejda/10000-MTV-Music-Artists-page-1.csv
10,000 MTV's Top Music Artists. Great dataset for machine learning, research and analysis. (name,facebook,twitter,website,genre,mtv).
name facebook twitter website genre mtv
Adele http://www.facebook.com/9770929278 http://www.twitter.com/officialadele Pop http://www.mtv.com/artists/adele/biography
Joey + Rory http://www.facebook.com/15044507815 http://www.twitter.com/joeyandrory Country http://www.cmt.com/artists/joey-rory/biography
Draaco Aventura http://www.facebook.com/856796091053581 http://www.twitter.com/DraacoAventura http://www.bandpage.com/draacoaventura Pop Latino http://www.mtv.com/artists/draaco-aventura/biography
Justin Bieber http://www.facebook.com/309570926875 http://www.twitter.com/justinbieber http://www.justinbiebermusic.com Pop http://www.mtv.com/artists/justin-bieber/biography
Peer van Mladen http://www.facebook.com/264487966 http://www.twitter.com/Predrag_Jugovic http://pejaintergroup.eu/Peer_van_Mladen.html House http://www.mtv.com/artists/peer-van-mladen/biography
Chris Janson http://www.facebook.com/296647641825 http://www.twitter.com/janson_chris http://www.chrisjanson.com Country http://www.cmt.com/a
@alexfilatov
alexfilatov / Indian-Female-Names.csv
Created March 7, 2018 15:25 — forked from mbejda/Indian-Female-Names.csv
Dataset of ~14,000 Indian female names for NLP training and analysis. The names have been retrieved from public records. (name,gender,race)
name gender race
shivani f indian
isha f indian
smt shyani devi f indian
divya f indian
mansi f indian
mazida f indian
pooja f indian
kajal f indian
meena f indian
@alexfilatov
alexfilatov / Indian-Male-Names.csv
Created March 7, 2018 15:25 — forked from mbejda/Indian-Male-Names.csv
Dataset of ~14,000 Indian male names for NLP training and analysis. The names have been retrieved from public records. (name,gender,race)
name gender race
barjraj m indian
ramdin verma m indian
sharat chandran m indian
birender mandal m indian
amit m indian
kushal m indian
kasid m indian
shiv prakash m indian
vikram singh m indian
@alexfilatov
alexfilatov / Hispanic-Female-Names.csv
Created March 7, 2018 15:25 — forked from mbejda/Hispanic-Female-Names.csv
Dataset of ~200 hispanic female names for NLP training and analysis. The names have been retrieved from US public inmate records. (last name, first name,gender,race).
last name first name gender race
adams shirley m f hispanic
alonso ana d f hispanic
alonzo miriam f hispanic
alvarez ivette f hispanic
amador saray f hispanic
batista niurka f hispanic
betancourt maria f hispanic
blake merienne f hispanic
boyd rosalinda n f hispanic
@alexfilatov
alexfilatov / Hispanic-Male-Names.csv
Created March 7, 2018 15:25 — forked from mbejda/Hispanic-Male-Names.csv
Dataset of ~4,000 hispanic male names for NLP training and analysis. The names have been retrieved from US public inmate records. (last name, first name,gender,race).
last name first name gender race
abad jonathan r m hispanic
abellas-bauzo jonathan a m hispanic
abreu pablo m hispanic
abreu sosa basilio l m hispanic
abreu-bolano german m hispanic
abreu-perez javier m hispanic
abrew luis a m hispanic
acevedo angel m hispanic
acevedo antonio m hispanic