- You can store a price in a floating point variable.
- All currencies are subdivided in 1/100th units (like US dollar/cents, euro/eurocents etc.).
- All currencies are subdivided in decimal units (like dinar/fils)
- All currencies currently in circulation are subdivided in decimal units. (to exclude shillings, pennies) (counter-example: MGA)
- All currencies are subdivided. (counter-examples: KRW, COP, JPY... Or subdivisions can be deprecated.)
- Prices can't have more precision than the smaller sub-unit of the currency. (e.g. gas prices)
- For any currency you can have a price of 1. (ZWL)
- Every country has its own currency. (EUR is the best example, but also Franc CFA, etc.)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| DO WTF YOU WANT TO PUBLIC LICENSE | |
| Version 2, December 2004 | |
| Copyright (C) 2011 Alexey Silin <pinkoblomingo@gmail.com> | |
| Everyone is permitted to copy and distribute verbatim or modified | |
| copies of this license document, and changing it is allowed as long | |
| as the name is changed. | |
| DO WTF YOU WANT TO PUBLIC LICENSE |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Copyright (c) 2017 Ismael Celis | |
| // Permission is hereby granted, free of charge, to any person obtaining a copy | |
| // of this software and associated documentation files (the "Software"), to deal | |
| // in the Software without restriction, including without limitation the rights | |
| // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
| // copies of the Software, and to permit persons to whom the Software is | |
| // furnished to do so, subject to the following conditions: | |
| // The above copyright notice and this permission notice shall be included in all |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Mytype must implement Less func. | |
| func SortedInsert (s []Mytype, f Mytype) []Mytype { | |
| l:=len(s) | |
| if l==0 { return [f] } | |
| i := sort.Search(l, func(i int) bool { return s[i].Less(f)}) | |
| if i==l { // not found = new value is the smallest | |
| return append([f],s) | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| id,type | |
| 1,Workshop | |
| 2,Conference | |
| 3,Lightning | |
| id,presenter,presentation_title,slide_link,repo_link,presentation_type_id,created,updated | |
| 2,"Curtis Gibby",PHP_CodeSniffer,http://slides.com/curtisgibby/cakefest-phpcs,,3,"2015-05-31 18:01:04",NULL | |
| 3,"Brian Porter","Running a CakePHP App in Different Operating Environments",https://github.com/beporter/CakePHP-EnvAwareness/raw/master/slides/env-aware-cake-apps.pdf,https://github.com/beporter/CakePHP-EnvAwareness,2,"2015-05-31 18:02:11",NULL |
A running example of the code from:
- http://marcio.io/2015/07/handling-1-million-requests-per-minute-with-golang
- http://nesv.github.io/golang/2014/02/25/worker-queues-in-go.html
This gist creates a working example from blog post, and a alternate example using simple worker pool.
TLDR: if you want simple and controlled concurrency use a worker pool.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| Optional adjustments for md-autocomplete in mobile screens | |
| */ | |
| #place-autocomplete > md-autocomplete md-input-container { | |
| margin-top: -10px; | |
| } | |
| /*Media query for tablets and above */ |
Run go install and
gogitlocalstats -add /path/to/folderwill scan that folder and its subdirectories for repositories to scangogitlocalstats -email your@email.comwill generate a CLI stats graph representing the last 6 months of activity for the passed email. You can configure the default inmain.go, so you can rungogitlocalstatswithout parameters.
Being able to pass an email as param makes it possible to scan repos for collaborators activity as well.
