javascript best practices
coding style
articles
- javascript_best_practises : qooxdoo.org
- javascript : Douglas Crockford
- Onze idées fausses sur l’héritage en JavaScript : sylvainpv.developpez.com - 20150523 (trad article Eric Elliott)
- The Complete JavaScript Handbook - medium.freecodecamp.org - 20181030
Table of Contents
- ECMAscript
- ES6
- ES2016
- ES2017
- ES2018
- Coding Style
- Lexical Structure
- Variables
- Types
- Expressions
- Prototypal Inheritance
- Classes
- Exceptions
- Semicolons
- Quotes
- Template Literals
- Functions
- Arrow Functions
- Closures
- Arrays
- Loops
- Events
- The Event Loop
- Asynchronous Programming and Callbacks
- Promises
- Async and Await
- Loops and Scope
- Timers
- This
- Strict Mode
- Immediately-Invoked Function Expressions (IFFE’s)
- Math Operators
- The Math Object
- ES modules
- CommonJS
- Glossary
perfs
Intensive JavaScript - developer.mozilla.org
By default the browser uses a single thread to run all the JavaScript in your page as well as to perform layout, reflows, and garbage collection. This means that long-running JavaScript functions can block the thread, leading to an unresponsive page and a bad user experience.
You can use the Frame rate and Waterfall tools to see when JavaScript is causing performance problems, and to single out the particular functions that need attention.
In this article we’ll take an example site whose long-running JavaScript causes responsiveness problems, and apply two different approaches to fixing them. The first is to split long-running functions into pieces and use
requestAnimationFrame
to schedule each piece, and the second is to run the whole function in a separate thread using a web worker.
undefined & null check
javascript strict mode
Strict mode : developer.mozilla.org
Le mode strict apporte quelques changements à la sémantique « normale » de JavaScript :
- le mode strict élimine quelques erreurs silencieuses de JavaScript en les changeant en erreurs explicites (une exception sera levée)
- le mode strict corrige les erreurs qui font qu’il est difficile pour les moteurs JavaScript d’effectuer des optimisations (exécution plus rapide)
- le mode strict interdit les mot-clés susceptibles d’être définis dans les futures versions de ECMAScript
online tools
array iteration
Loop through an array in JavaScript : stackoverflow.com
For-each over an array in JavaScript? : stackoverflow.com
Array.forEach n’est pas toujours la meilleure solution ! - blog.overnetcity.com - 20140829
array
/ object
/ Map
/ Set
definitions
array
const fruits = ['Apple', 'Banana'];
console.log(fruits.length);
// 2
It’s an indexed list.
Never use the new constructor (const list = new Array();
), always use directly the literal (const list = [];
).
The constructor is slower and there is a common mistake with it, when an array is instantiated with only one arg you define the array length, and not an array of one element :const list = new Array(2); // the array contains in fact [undefined, undefined], but const list = new Array(1, 2) leads to [1, 2]
.
Resize automatically. Order preserved (‘cause indexed). Any types in it. Values can be duplicated (const list = [1, 2, 2, 2, 'toto'];
)
See MDN for details.
object
const fruit = { name: 'Apple' };
See Object initializer in MDN for details with new
keyword or Object.create()
function.
The const object = new Object();
is rarely used.
The const object = Object.create(proto);
is used to create an object based on a proto
prototype. const object = Object.create(null);
allows object creation without any prototype.
An object is a key/value dictionnary.
A key must be unique and a string (or a Symbol). Keys are unordered, use Map instead if you need to keep an order.
Values can be of any types.
Can’t get the size (numbers of K/V) easily.
Map
var myMap = new Map();
var keyString = 'a string',
keyObj = {},
keyFunc = function() {};
// setting the values
myMap.set(keyString, "value associated with 'a string'");
myMap.set(keyObj, 'value associated with keyObj');
myMap.set(keyFunc, 'value associated with keyFunc');
myMap.size; // 3
// getting the values
myMap.get(keyString); // "value associated with 'a string'"
myMap.get(keyObj); // "value associated with keyObj"
myMap.get(keyFunc); // "value associated with keyFunc"
myMap.get('a string'); // "value associated with 'a string'"
// because keyString === 'a string'
myMap.get({}); // undefined, because keyObj !== {}
myMap.get(function() {}) // undefined, because keyFunc !== function () {}
A key must be unique and from any type (including function).
Keys are ordered.
There is a size()
function to get the K/V number.
Map is iterable.
A Map may perform better in scenarios involving frequent addition and removal of key pairs.
Set
const set1 = new Set([1, 2, 3, 4, 5]);
console.log(set1.has(1));
// expected output: true
// ...
// iterate a Set
for (let item of mySet) console.log(item);
Set
objects are collections of values. You can iterate through the elements of a set in insertion order. A value in the Set
may only occur once; it is unique in the Set
‘s collection.
Set
, more familiar as a Math concept, is an abstract data type which contains only distinct elements/objects without the need of being allocated orderly by index.
A Set
is fundamentally different with an Array
, a Set
is a keyed collection where an Array
is an indexed collection.
Indexed collections are collections of data which are ordered by an index value
Keyed collections are collections which use keys; these contain elements which are iterable in the order of insertion.
articles
Array in Indexed collections article - MDN
Maps and Sets in Key collections article - MDN
Map vs Object — What and when? - Maya Shavin - medium.com - 20180201
Set vs Array — What and when? - Maya Shavin - medium.com - 20180124
async
/ await
Coder l’asynchrone en Javascript (Par Matthieu Lux)
Tasks, microtasks, queues and schedules - jakearchibald.com - 20150817
In summary:
- Tasks execute in order, and the browser may render between them
- Microtasks execute in order, and are executed:
- after every callback, as long as no other JavaScript is mid-execution
- at the end of each task
Commentaire SylvainPV sur dev.com (fil privé) :
Ce qu’il faut retenir, c’est qu’un
Promise.resolve
n’entraîne pas de “vrai asynchronisme”, c’est-à-dire qu’il n’attend pas la prochaine boucle d’événements. On a besoin d’attendre la boucle d’événements pour laisser le navigateur faire le rendu et ne pas avoir de freeze.
TLDR :
The
async
keyword before a function has two effects:
- Makes it always return a promise.
- Allows to use
await
in it.The
await
keyword before a promise makes JavaScript wait until that promise settles, and then:
- If it’s an error, the exception is generated, same as if
throw error
were called at that very place.- Otherwise, it returns the result, so we can assign it to a value.
Together they provide a great framework to write asynchronous code that is easy both to read and write.
With
async/await
we rarely need to writepromise.then/catch
, but we still shouldn’t forget that they are based on promises, because sometimes (e.g. in the outermost scope) we have to use these methods. AlsoPromise.all
is a nice thing to wait for many tasks simultaneously.
drawbacks
How to escape async/await hell
TLDR : use successives
await
when not needed, the program control flow should continue. UsePromise.all
when needed.
design patterns
The Comprehensive Guide to JavaScript Design Patterns - www.toptal.com - Marko Mišura - 201803xx
Learning JavaScript Design Patterns - Volume 1.7.0 - Addy Osmani - 2017
Table of Content
- Introduction
- What is a Pattern?
- “Pattern”-ity Testing, Proto-Patterns & The Rule Of Three
- The Structure Of A Design Pattern
- Writing Design Patterns
- Anti-Patterns
- Categories Of Design Pattern
- Summary Table Of Design Pattern Categorization
- JavaScript Design Patterns
- Constructor Pattern
- Module Pattern
- Revealing Module Pattern
- Singleton Pattern
- Observer Pattern
- Mediator Pattern
- Prototype Pattern
- Command Pattern
- Facade Pattern
- Factory Pattern
- Mixin Pattern
- Decorator Pattern
- Flyweight Pattern
- JavaScript MV* Patterns
- MVC Pattern
- MVP Pattern
- MVVM Pattern
- Modern Modular JavaScript Design Patterns
- AMD
- CommonJS
- ES Harmony
- Design Patterns In jQuery
- Composite Pattern
- Adapter Pattern
- Facade Pattern
- Observer Pattern
- Iterator Pattern
- Lazy Initialization Pattern
- Proxy Pattern
- Builder Pattern
- jQuery Plugin Design Patterns
- JavaScript Namespacing Patterns
- Conclusions
- References
class
How to Use Classes and Sleep at Night - Dan Abramov - 20151015
Problem :
- Classes obscure the prototypal inheritance at the core of JS.
- Classes encourage inheritance but you should prefer composition.
- Classes tend to lock you into the first bad design you came up with.
How to use classes and sleep at night :
- Resist making classes your public API.
- Don’t inherit more than once.
- Don’t make
super
calls from methods. - Don’t expect people to use your classes.
- Learn functional programming
Applied to React :
- You can use
class
in your JS if you don’t inherit twice and don’t usesuper
. - Prefer to write React components as pure functions when possible.
- Use ES6 classes for components if you need the state or lifecycle hooks.
- In this case, you may only extend
React.Component
directly. - Give your feedback to the React team on the functional state proposals.


Reports calls to
java.util.Optional.get()
without first checking with a
isPresent()
call if a value is available. If the
Optional
does not contain a value,
get()
will throw an exception.
New in 16


| |
Go to:
[Product Pages]
[Technical Innovations]
PRODUCT PAGES
TECHNICAL INNOVATIONS
- Multiple input-output nonlinear fnction approximation using neural networks objectivized with permutation grids
- Automated cluster analysis with smart seeding and stopping conditions for spatial partitioning
- Automated Gaussian mixture models for fitting arbitrary & lognormal distributions
- Spectral windowing by convolution of solar irradiance spectra with spectral weighting functions
- Automated nonlinear time series decomposition/li>
|
|


Run mkCOInr¶
The scripts were written and tested on Linux. MacOS users will probably be able to run them. I suggest WSL for Windows users.
To run any of the scripts, open a terminal in the ‘scripts’ folder and type
cd ~/mkCOInr/scripts
perl name_of_the_script.pl -argument_name argument_value
This list of arguments and options can be obtained by typing
perl name_of_the_script.pl -help


Phone
Portfolio
-
Web design
April 18
-
Profile Card
April 20
-
Mobile App
April 21
-
Business Card
April 22
-
Website design
April 25
-
Branding/Logo Design
May 04
-
Logo Design
May 04
-
Logo Design
July 16
-
Dribbble Meetup
July 22
-
Freehand
July 28
-
Abstract 3D
August 14
-
Analytical Website
December 31
John Donga Greepit.com
I have always received good service from the Dubbizal Templates. Timing and quality have always met my expectations and everything is communicated in a professional and timely manner.
John Donga Frittt.com
We consider the Dubbizal Templates team a development partner who has proven to be creative in problem resolution, reliable in time commitments, and overall consistent in meeting our expectations.
John Donga www.Frittt.com


More web tech?
So where's all the web tech stuff? Well, the flash pages are over in
this direction, and
there's some useful applications over here.
There's even a video of the browser everyone should be using over
here.
The only thing left is CSS...
So here we go.
The only thing left is CSS...
So here we go.
CSS stands for Cascading Style Sheets. Using CSS allows someone to use
similar styles (font color, text size, backgrounds...) on mulitple pages,
without having to copy pasta the same section of code over 9000 times. Using
CSS also allows someone to easily change their entire website by simply modifying
one CSS class file. You can even link multiple files on the same page and
specify different mediums for which they'll display, allowing your mom's Iphone
and your brother's PSP to use a different style sheet and layout!
The primary reason CSS is "cascading" is because of the fact mentioned above,
being able to link multiple sheets to the same document. Every page of this site
uses 2-3 CSS files (1 being the printer page, which can be seen in the 'print
this page' section of the 'Form' page).


@* * This template is called from the `index` template. This template * handles the rendering of the page header and body tags. It takes * two arguments, a `String` for the title of the page and an `Html` * object to insert into the body of the page. *@ @import helper._ @(title: String, user: models.users.User)(content: Html)
@* Here's where we render the page title `String`. *@


HTML Wysiwyg editor
allows users to edit HTML content without having to type or remember names of HTML tags and attributes.
Among other things the editor provides the following features:
Text formatting and alignment.
Ordered and unordered lists.
Links and images inserting.
Font and background color changing.
Open Insert or Edit forms to see the editor in action.


Comunity
E-Mail
Mobile
About us
Hi there!

Yes! Let´s Code!


D3.js workshop III: Binding Data to the DOM
<EMAIL_ADDRESS>roadtolarissa.com
NYC Open Data
github.com/1wheel/tutorial
D3 creates interactive data visualizations for the web
512 Paths to the White House
Twisters
Tax Rates
D3 is built on web standards
HTML
CSS
SVG
JavaScript
Get Started!

Stack Overflow


Welcome to http4s!
You are running atop the blaze native backend. Use the navbar to see examples.
Source available on github.
Both http4s and blaze are works in progress: if you find bugs or have suggestions,
please submit an issue.


Level 100 character build that utilizes 2 1-handed melee weapons. Race: Half-Giant Levels: * Combat: 0 * Melee: 100 * 20 Fortitude * 20 Critical Strike * 20 Dual Wield * 20 Alacrity * 20 Deadly Strike * Nature: 0 * Ranged: 0


|
KAMISHIBAI
|
Properties | |
| bool | AlwaysAppendDefaultExtension [get, set] |
| Gets or sets a value that controls whether the returned file name has a file extension that matches the currently selected file type. If necessary, the dialog appends the correct file extension. More... | |
| bool | CreatePrompt [get, set] |
| Gets or sets a value that controls whether to prompt for creation if the item returned in the save dialog does not exist. More... | |
| bool | IsExpandedMode [get, set] |
| Gets or sets a value that controls whether to the save dialog displays in expanded mode. More... | |
| bool | OverwritePrompt [get, set] |
| Gets or sets a value that controls whether to prompt before overwriting an existing file of the same name. Default value is true. More... | |
| Properties inherited from FileDialogContext | |
| bool | AddToMostRecentlyUsedList = true [get, set] |
| Gets or sets a value that controls whether to show or hide the list of places where the user has recently opened or saved items. More... | |
| bool | AllowPropertyEditing = false [get, set] |
| Gets or sets a value that controls whether properties can be edited. More... | |
| Guid | CookieIdentifier = Guid.Empty [get, set] |
| Gets or sets a value that enables a calling application to associate a GUID with a dialog's persisted state. | |
| string | DefaultDirectory = string.Empty [get, set] |
| Sets the folder and path used as a default if there is not a recently used folder value available. | |
| string | DefaultExtension = string.Empty [get, set] |
| Gets or sets the default file extension to be added to file names. If the value is string.Empty, the extension is not added to the file names. | |
| string | DefaultFileName = string.Empty [get, set] |
| Default file name. | |
| virtual bool | EnsureFileExists = true [get, set] |
| Gets or sets a value that determines whether the file must exist beforehand. More... | |
| bool | EnsurePathExists = true [get, set] |
| Gets or sets a value that specifies whether the returned file must be in an existing folder. More... | |
| bool | EnsureReadOnly = true [get, set] |
| Gets or sets a value that determines whether read-only items are returned. Default value for CommonOpenFileDialog is true (allow read-only files) and CommonSaveFileDialog is false (don't allow read-only files). More... | |
| bool | EnsureValidNames = false [get, set] |
| Gets or sets a value that determines whether to validate file names. More... | |
| string | FileName = string.Empty [get, set] |
| Gets the selected filename. More... | |
| IList< FileDialogFilter > | Filters = new List<FileDialogFilter>() [get, set] |
| Gets the filters used by the dialog. | |
| string | InitialDirectory = string.Empty [get, set] |
| Gets or sets the initial directory displayed when the dialog is shown. A null or empty string indicates that the dialog is using the default directory. More... | |
| bool | NavigateToShortcut = true [get, set] |
| bool | RestoreDirectory [get, set] |
| Gets or sets a value that determines the restore directory. More... | |
| bool | ShowHiddenItems [get, set] |
| bool | ShowPlacesList = true [get, set] |
| Gets or sets a value that controls whether to show or hide the list of pinned places that the user can choose. More... | |
| string | Title = string.Empty [get, set] |
| Gets or sets the dialog title. More... | |
| IList< FileDialogCustomPlace > | CustomPlaces = new List<FileDialogCustomPlace>() [get, set] |
| An item in the "Place" section to add to the list of locations where users can open or save items. | |
|
getset |
Gets or sets a value that controls whether the returned file name has a file extension that matches the currently selected file type. If necessary, the dialog appends the correct file extension.
This property cannot be changed when the dialog is showing.
|
getset |
Gets or sets a value that controls whether to prompt for creation if the item returned in the save dialog does not exist.
Note that this does not actually create the item.
This property cannot be changed when the dialog is showing.
|
getset |
Gets or sets a value that controls whether to the save dialog displays in expanded mode.
Expanded mode controls whether the dialog shows folders for browsing or hides them.
This property cannot be changed when the dialog is showing.
|
getset |
Gets or sets a value that controls whether to prompt before overwriting an existing file of the same name. Default value is true.
This property cannot be changed when the dialog is showing.


(load "aima.lisp") (aima-load 'name)Where name is the name of a system you want to work with. The systems that are currently defined are:
utilities (Automatically loaded when you load aima.lisp) agents (Part I: Agents and Environments) search (Part II: Problem Solving and Search) logic (Part III: Logic, Inference, and Knowledge Rep.) planning (Part IV: Planning and Acting) uncertainty (PART V: Uncertain Knowledge and Reasoning) learning (Part VI: Learning) language (Part VII, Chapters 22-23: Natural Language) all (All the above, except utilities)Not all Lisps are clever enough to figure out when to load binary (compiled) files, and when to load lisp (source) files. If your Lisp has trouble with this, and you want to load the binary files, then instead of (aima-load 'name) you can do (aima-load-binary 'name)
(test 'agents)
This will print a transcript of various operations from the agent code. Besides printing the transcript, it also counts up the number of unexpected answers, and returns the total at the end. If this is not 0, it means something is wrong. The most recent run of (test 'all) on a Sparc-10 took about a minute total. But it may take longer if you have a slower machine, if you have not compiled the files first, or if you just have bad luck: many of the tests involve generating random environments, and there is a chance that a particularly difficult environment will be generated, and the agents will perform slowly on it. If you have to wait more than a minute or two for any one environment, you might want to abort out of the test and try again.
| AIMA Home | Contact Russell & Norvig | What's new | Changed 10/02/2001 |


1) Intro to basic text-based computer interfaces: bash and vim¶
Before we get into programming with python, we’ll cover interacting with computers using bash, a convient and fast route to file handing and much more.
Related text: Chapter 1 of Introduction to Scientific and Technical Computing
Optional related tutorials: http://swcarpentry.github.io/shell-novice/ https://danielmiessler.com/study/vim/#null
Shell overview¶
Many of the programs we use have GUIs: Graphical User Interfaces. Direct text input can often save quite a bit of time and allow additional functionality. While the tasks in this class will be able to be completed on a laptop or desktop (in any operating system), scientific computing generally requires larger, remote resources that are typically Unix or Unix-like systems. In those systems, the primary mode of user iteraction with the operating system is via text-based shell processes.
There are several different types of shells, including csh/tcsh, sh/Bash, ksh, and zsh. The most common type, and the only one we will discuss is bash, the Bourne-again shell. The associated reeading gives more detail on why bash is the way to go. FYI: if you are given an account on a Unix-based computer, the default shell assigned is usually bash, but this is an option you can change. Look to resources like https://stackoverflow.com/ will give you instructions to implement that.
Mac OSX is built on a Unix platform and has a built-in program, terminal, that provides shell. The default type is bash. The preferences will allow you to change to another type. For this class, we’ll stick with bash as it the one that will likely serve you best. FYI: bash on OSX is mostly the same as bash on a Linux machine, but there are a few differences (e.g., see https://unix.stackexchange.com/questions/82244/bash-in-linux-v-s-mac-os). This is good to remember if you see different behavior for the same command on these two types of machines.
Windows computers do not have a built-in Unix-like shell, but have shell emulators. There are many options, including https://www.putty.org/. Windows 10 now allows you to install Linux (see, for example, https://docs.microsoft.com/en-us/windows/wsl/install-win10) which is another route to get you to a bash shell.
For the first homework, you will need to write and run bash commands.
You will find bash scripts and commands useful throughout this course. They can even be invoked from within a python program.
Some key points from the Software carpentry module on bash:¶
- A shell is a program whose primary purpose is to read commands and run other programs.
- The shell’s main advantages are its high action-to-keystroke ratio, its support for automating repetitive tasks, and its capacity to access networked machines.
- The shell’s main disadvantages are its primarily textual nature and how cryptic its commands and operation can be.
Some basic, extremely useful bash commands¶
First, open a bash session (e.g. launch terminal on your mac).
Enter the following commands (one at a time), and note what you see:
pwd
ls
ls -F
ls -a
ls -lhatr
man ls
which ls
Use cd
to navigate to a different directory. Then cd
to yet
another directory. Now, explore what happens when you: - enter only
cd
- then enter cd -
- enter cd ..
- enter cd .
- enter
cd ../..
Other common, useful commands include:
cp
rm
mv
mkdir
cat
tail
head
wget
diff
wc
find
There are multiple ways to learn what they do, including reading the
related text, using man
’, and, of course, asking the internet.
There are great tutorials for those interested in learning more (see
link at the beginning of this notebook), which will pay off if you are a
computational researcher. For this course, make sure you learn some
basics, which we will go over today and practice on HW01.
Quick note on directories: to copy or delete a directory, you’ll need to
add the flag -r
, e.g. cp -r test_dir
. However, be very, very
careful with this. rm
is forever.
*
is wild. It can be very helpful! e.g. ls *.dat
will display
all the files in the current folder that have the .dat
extention.
Some of my favorite bash time-saving tips¶
- When you change your mind about what you want to type,
ctrl-u
clears the line. This is especially helpful when you are typing a password and may have made a typo; this lets you quickly start again - Want to run a command again?  You can also use
ctrl-r
to reverse search through your history ctrl-a
moves the cursor to beginning of the linectrl-e
moves the cursor to the end of the line
Customizing bash¶
In your home directory (e.g. type cd $HOME
), you may have both a
.bash_profile
and .bash_rc
. It can be confusing why there are
two places you can customize bash, and where to put what, as described
in multiple places such as:
http://www.joshstaiger.org/archives/2005/07/bash_profile_vs.html
This and other source recommend editing .bashrc
only, and making
sure this is run by adding the following to your .bash_profile
:
if [ -f ~/.bashrc ]; then
source ~/.bashrc
fi
One customization I make sure to always add:
export CLICOLOR=1
export LS_COLORS='di=1;35'
The first line turns on color coding (e.g. use specified colored text for directories, etc.), and the second defines colors to use. Here “di” stands for directories, and the numbers after that mean bold;purple (you do not need to memorize these numbers!).
There are many options for defining colors, and many suggestions. This happens to the be choice I use. An internet search will provide many websites with details on the codes and alternate suggestions (for example, http://www.bigsoft.co.uk/blog/2008/04/11/configuring-ls_colors).
You can also set up aliases to save time. e.g.:
alias vmd="/Applications/VMD\ 1.9.3.app/Contents/MacOS/startup.command"
alias flux="ssh<EMAIL_ADDRESS>This lets me quickly launch vmd from my command line.
Pro tip: .bash_profile
and .bashrc
are only loaded when a new
bash instance in launched. To take the changes take place immediately,
check the file in with . .bash_profile
(since this file will launch
.bashrc, both do not need to be checked in). > FYI: It will only be
checked in for that shell. If several instances were open before the
change was made, the file needs to be checked in for each, or the
instance closed and reopened.
Recommended text editor: vim¶
Because of the breadth of functinoality, there is some start-up time to learn how to use it. There are many tutorials, such as https://danielmiessler.com/study/vim/#null and http://www.openvim.com/, that will be extremely helpful to the computational researcher. Some basic essentials are shared below.
FYI: some people prefer emacs. Vim is lightweight (doesn’t require as much computer resources) and more popular, so it is introduced here.
Customizing vim¶
In your home directory, you can make a .vimrc
file (if there is not
already one there) to make changes to your default configuration. My
favorite additions are:
set ruler
:syntax on
The ruler shows you what line and column you are on. The :syntax on
option provides helping coloring of key words.
You can also set up spell check and may other options in your
.vimrc
. See https://danielmiessler.com/study/vim/#null for several
suggestions, if you are interested.
‘Normal’ and ‘insert’ modes¶
Some basics: When you first open a file with vim, you will be in
‘normal’ mode. To enter text, you need to be in ‘insert’ mode. Type
i
to enter insert mode. When you are done typing (or pasting from
your buffer), press esc
to return to ‘normal’ mode.
There are other ways to enter insert mode. Typing ‘o’ will enter insert
mode on a new line below your curser, while O
will enter insert mode
on a new line above your curser.
In the normal mode, u
undoes the last action. .
repeats the last
action.
FYI: the tutorials will show you ways of entering words or characters with a specified number of repeats, replacing a letters or words (without having to go in and out of insert mode), and more time-saving tips. There are also other modes, such as the visual mode, which can be handy in selecting/inserting/deleting text, especially column-wise.
Copy and Paste¶
There is a different vim buffer from your computer’s cut buffer. If you copy text to your computer buffer (command-c), you can paste into vim by first entering the insert mode and then pasting from the computer cut butter (command-v).
If you want to cut and paste within your file in vim, vim offers
additional functionality. d
stands for delete and acts like cutting;
y
for yank and acts like copying; p
is for paste.
Enter dd
or yy
to delete or copy one line. If you want to
perform the operation on the current line plus the next 2 lines, type
d3
and then enter/return (no enter/return is needed with just
dd
). Whether deleted or yanked, those line(s) will now be in vim’s
buffer. p
will place those lines below your cursor. Before pasting,
you can move your cursor as desired. You can paste multiple types by
entering a number before p
, e.g. 10p
to paste the line(s) 10
times.
Saving and exiting¶
To save: while in normal mode, enter :w
. To quit, enter :q
. If
you try to quit without first saving, vim will warn you, tell you how to
exit without saving (:q!
). To save and exit together, type :wq
.
Caution: vim will put your file in editing mode, which is not always appropriate!¶
You may want to look at the output of a file while it is being
generated. Opening it in vim can interfere with proper additional
output. You can safely view such files by using alternate bash commands
or unix utilities, such as cat
, tail -f
, less
, or more
.
Reusable bash scripts¶
Series of bash commands can be saved as a script and by executing the
script. For example, make a file called bananas.sh
with the
following contents:
The shebang and more¶
Before running this code, let’s look at the parts. #!
is
colloquially called the shebang. It is not strictly necessary in this
case, but is good practice. If it were not included, the script would be
run as a bash script if your shell is bash. However, including this in
your script will ensure it is run as a bash script even if your shell is
tsch, etc., with a shortcut (see below). It will also specify which bash
instance will be used to run the script.
echo
followed by the redirect symbol (>
) will put the echoed
text into a file. The strings first=
, etc., define variable names.
Variables are then used by typing the $
and then the variable name.
You do not need to enclose the variable name in curley braces ({}
)
unless there is a special character in the name (e.g. a space) but it is
good practice as it can make it more readable and it never hurts to
include them, but sometimes can hurt to exclude them.
 Try:
$ ./bananas.shThe above is a shortcut to running any executable in the current folder.
Did it work? Probably not. Before you can run a script, the computer has
to know that it is an executible. We do that with the command chmod
.
This is a powerful command that can change read (r), write (w), and
excute (x) abilities for everyone, a group, and yourself. Before
changing access, see what it is by typing ls -l bananas.sh
. Now,
make the file an excutable by entering:
Now see how the permissions have changed by typing ls -l bananas.sh
,
and then try excuting the file again with the command ./bananas.sh
.
FYI: you can also run the script by entering the command
bash bananas.sh
. That’s just more typing, though!
Note: The double quotes (" "
) are important when you want to use
a variable inside the quote, because it will allow the variable to be
interpreted. What happens if you change the double-quotes on the line
starting with sed
to single-quotes?
There are multiple very handy ways to loop through values. Above was an numerical loop, with the first and last numbers explicitly entered at the top of the file, as well as the increment value. Here are some other examples of loops. What changes should be made to the text below?
#!/usr/bin/env bash for student in Agnes Alex Alyssa; do echo 'May ${student} have some bananas?' doneIt can be very handy to have lines of a text file be the list that is
iterated. I have a file named students.txt
, with line name per line,
such as
Agnes
Alex
Alyssa
Carolina
Chloe
Christina
...
With just the commands listed here on this brief intro to bash scripting, you can make templates and thus automate many repative tasks!
A note on file names¶
Most file names are something.extension
. The extension isn’t
required and doesn’t guarantee anything, but is normally used, and best
practice to use it, to indicate the type file. txt
is used for text
files, and sh
for bash scripts, .py
for python scripts, etc.
If you only learn one thing in this class, please learn this: please don’t use spaces or special characters in your file names. Use only letters, numbers, _, - (although - should never be the first letter, bash will interpret it as a flag; if . is used first, it will be a ‘hidden’ file), and then a period followed by the appropriate extension
Please keep these files for some practice below.
Other great utilities and functions¶
To help us explore these utilities, make a file stp.txt
with the
contents:
Algorhyme
I think that I shall never see
A graph more lovely than a tree.
A tree whose crucial property
Is loop-free connectivity.
A tree which must be sure to span
So packets can reach every LAN.
First the root must be selected.
By ID it is elected.
Least cost paths from root are traced.
In the tree these paths are placed.
A mesh is made by folks like me
Then bridges find a spanning tree.
--From the paper "An Algorithm for Distributed Computation of a Spanning Tree in an Extended LAN" by Radia Perlman, inventor of the spanning tree protocol.
grep
¶
This utility searches for strings in files. It has many functions. It can search in one or many files. By default, it returns the line with the matching word, but that can be adjusted (e.g. return lines before or after).
In the directory with the files stp.txt
, enter the command:
grep tree stp.txt
. What do you see?
In the directory with the files
banana_2.txt banana_4.txt banana_6.txt banana_8.txt
, enter the
command: grep banana *.txt
. What do you see?
Directing input and output¶
<
indicates that the file name after the character should be treated
as input to the action preceeding the character. For grep, the input
file is known based on its position, but we could also directly specifcy
it.  For working with grep and these files, >
can be very useful. Try this; the first command should return a erorr
that there is no such file, which is what we want (or it would be
overwritten in following steps):
ls all_bananas.txt
grep banana *.txt > all_bananas.txt
ls all_bananas.txt
cat all_bananas.txt
In this case, the >
will overwrite anything in the file
all_bananas.txt
if the file had existed. What if we just wanted to
add it to the end? >>
will accomplish that. >>
will act the same
as >
if the file did not previously exist, so let’s use with the
file we just made (all_bananas.txt
). First, I check that the file is
still there. If not, make it again as above.
cat all_bananas.txt
grep root stp.txt >> all_bananas.txt
cat all_bananas.txt
Combining commands¶
The |
character can feed the results of the first command to the
second command. Compare the commands below:
grep tree stp.txt > trees.txt
wc -l trees.txt
rm trees.txt
Versus:
grep tree stp.txt | wc -l
This is just one of many ways that bash commands can increase efficiencies.
sed¶
sed is a stream-line editor. It can function from the command line, within a bash script (as in the example above), or within vim.
Try the following commands:
cp stp.txt stp_edited.txt
diff stp.txt stp_edited.txt
sed 's/I/We/' stp_edited.txt
diff stp.txt stp_edited.txt
sed -i 's/I/We/' stp_edited.txt
Note: The above command words for Unix, but not on the Max OSX
terminal. There, use sed -i ' ' 's/I/We/' stp_edited.txt
. This
command will not work on Unix. This is an example of some of the small
difference between implementations on thse systems.
diff stp.txt stp_edited.txt
cp stp.txt stp_edited.txt
sed -i 's/I/We/g' stp_edited.txt
Note: again, on Mac OSx, follow -i
with ' '
diff stp.txt stp_edited.txt
Sed it a very powerful utilitiy; this is just a quick taste of the different options that can be invoked, including search and replace in-place (in the input file), changing only the first instance on a line, etc.
If you are interested in learning more about sed, one resource (of many) is: https://www.gnu.org/software/sed/manual/sed.html
Sed can also be used while in vim. See http://vim.wikia.com/wiki/Search_and_replace for some nice tricks!
awk for text processing and extraction¶
We will not spend much time on this powerful utility. Hereis one example of its functionality. There are many resources to learn more, should you be interested (e.g. https://likegeeks.com/awk-command/; https://www.gnu.org/software/gawk/manual/gawk.html#toc-Getting-Started-with-awk for a whole book on it).
I often use awk to print a column from a file. Key variables available
include: - $0
for the whole line. - $1
for the first field. -
$2
for the second field. - $n
for the nth field.
Try the following commands:
awk '{print $0}' all_bananas.txt
awk '{print $1}' all_bananas.txt
awk '{print $2}' all_bananas.txt
awk '{print $1,$3}' all_bananas.txt
This can be used in conjunction with other commands, (e.g. using |
)
to, for example:
tail -2n all_bananas.txt | awk '{print $1,$3}'
Summary¶
This is just a quick taste to help us use the bash shell for navitaging and editing files. We’ll practice using bash throughout the semester for our efficiency. It is not a main focus.
A very important tool will be jupyter notebooks, discussed next!


We drove out the orcs from the Great Gate and guardroom and took the First Hall. We slew many in the bright sun in the dale. Flói was killed by an arrow. He slew the great chieftain. We buried…Flói under grass near Mirrormere…came…ken we repaired…We have taken the Twenty-first Hall of North End to dwell in. There is good air…that can easily be watched…the shaft is clear…Balin has set up his seat in the Chamber of Mazarbul…gathered…gold…wonderful lay Durin’s Axe and…silver helm. Balin has taken them for his own. Balin is now lord of Moria:…today we found truesilver…well-forged helm…made all of purest mithril…Óin to seek for the upper armories of the Third Deep…go westwards to s…to Hollin Gate.
…years since…ready sorrow…yesterday being the tenth of November Balin, lord of Moria, fell in Dimrill Dale. He went alone to look in Mirrormere. An orc shot him from behind a stone. We slew the orc, but many more came…up from east up the Silverlode…we rescued Balin’s body..after a sharp battle…we have barred the gates but doubt if…we can hold them long. If there is…no escape it will be a horrible fate to suffer, but I shall hold.


Cryton SibandaSoftware development student at Varsity College I am currently finishing up my studies for bachelors in Computer Information Science. |
| Date | Experience |
|---|---|
| 2018 - 2020 | Developer |
| 2020 | Student |
| Skill | Rate |
|---|---|
| ReactJS | ⭐⭐⭐⭐ |
| HTML5 | ⭐⭐⭐⭐⭐ |
| CSS | ⭐⭐⭐ |
| JavaScript | ⭐⭐⭐ |
| Python | ⭐⭐⭐⭐ |
| MongoDB | ⭐⭐⭐⭐ |


{% extends "site_base.html" %} {% block head_title %}FAQs{% endblock %} {% block body_class %}faqs{% endblock %} {% block breadcrumbs %}
Not likely. Since everything you post on CoLab is time-stamped and available for the world (or at least your collaborators if you chose to make your issue private) to see, its easy to tell where an idea originated. Not so if your research is hidden in emails, lab notebooks, and post-it notes. Imagine how much easier life would have been for Isaac Newton if he had only used CoLab. Additionally, by exposing your research to the rest of the scientific community, you can get help from others inside and outside your field quickly and easily.
One of CoLab's core principles is the promotion of open science. In the spirit of open source software, open science takes the stance that a large community of intelligent users is better able to spot flaws and come up with new ideas than is a small, private group. We believe in rapid, complete, and free publication of data, lab notebooks, and brainstorming.
In case you're unconvinced or simply interested in learning more, check out these links:


sizeof
Syntax
sizeof (typeNameOrVariableReference)
Description
The sizeof attribute is used to find the number of bytes used to represent the type or variable. This is implementation-dependent (dirty).
Example
The size of int2 and nat2 is 2.
var i : int2
const nat2size := sizeof ( i ) % size is 2
Details
The typeNameOrVariableReference must be the name of a user-defined type, a variable reference, a basic type (such as real), or a constant.
In principle, sizeof returns the number of storage units which would not necessarily be 8-bit bytes. For example, in some older machines, such as the CDC 6000 series, the storage units are 60 bit words. However, almost all modern computers use 8-bit bytes so these are the units of sizeof.
Beware that sizes may reflect alignment constraints in the underlying computer. For example, string sizes may be rounded up to even values (2-byte word alignments).
See also
the indirection operator @, cheat, explicitIntegerConstant (how to write hexadecimal constants), and pointers (in particular unchecked pointers). See also addr, which returns the address of a variable.


--- title: Anouk Paradis position: PhD Student image: anouk.jpg email<EMAIL_ADDRESS>office: CNB H 100.5 ---
I am Anouk Paradis, a PhD student at the Department of Computer Science, ETH Zürich. I am part of the Secure, Reliable, and Intelligent Systems Lab, supervised by Martin Vechev, starting October 2020.
| 2021 | ETH Medal for Outstanding Master Thesis | Awarded |
| 2018 | ETH Foundation Excellence Scholarship | Awarded |


This is an archived post from Xanga.
Someone now warns us lest we become so heavenly minded that we are of no earthly use. The brutal, soul-shaking truth is that we are so earthly minded we are of no heavenly use.
—Leonard Ravenhill, Why Revival Tarries


[1]
This was a great product.; Nothing more to say
[2]
There really are none; Voice control is worthless and map's and routeing is way off


The file serves as input to the postmap(1) command. The result, an indexed file in dbm or db format, is used for fast searching by the mail system.
The canonical mapping affects both message header addresses (i.e. addresses that appear inside messages) and message envelope addresses (for example, the addresses that are used in SMTP protocol commands). Think Sendmail rule set S3, if you like.
Typically, one would use the canonical table to replace login names by Firstname.Lastname, or to clean up addresses produced by legacy mail systems.
The canonical mapping is not to be confused with virtual domain support. Use the virtual domain map for that purpose.
The canonical mapping is not to be confused with local aliasing. Use the mail aliases map for that purpose.
The format of the canonical mappings is as follows, mappings being tried in the order as listed:
ADDRESS EXTENSION: When table lookup fails, and the address localpart contains the optional recipient delimiter (e.g., user+foo@domain), the search is repeated for the unextended address (e.g. user@domain), and the unmatched extension is propagated to the result of table lookup. The matching order is: user+foo@domain, user@domain, user+foo, user, and @domain.


2019 pandas user survey
Pandas recently conducted a user survey to help guide future development. Thanks to everyone who participated! This post presents the high-level results.
This analysis and the raw data can be found on GitHub and run on Binder
We had about 1250 repsonses over the 15 days we ran the survey in the summer of 2019.
About the Respondents
There was a fair amount of representation across pandas experience and frequeny of use, though the majority of respondents are on the more experienced side.
We included a few questions that were also asked in the Python Developers Survey so we could compare Pandas' population to Python's.
90% of our respondents use Python as a primary language (compared with 84% from the PSF survey).
Yes 90.67%
No 9.33%
Name: Is Python your main language?, dtype: object
Windows users are well represented (see Steve Dower's talk on this topic).
Linux 61.57%
Windows 60.21%
MacOS 42.75%
Name: What Operating Systems do you use?, dtype: object
For environment isolation, conda was the most popular.
Most repondents are Python 3 only.
3 92.39%
2 & 3 6.80%
2 0.81%
Name: Python 2 or 3?, dtype: object
Pandas APIs
It can be hard for open source projects to know what features are actually used. We asked a few questions to get an idea.
CSV and Excel are (for better or worse) the most popular formats.
In preperation for a possible refactor of pandas internals, we wanted to get a sense for how common wide (100s of columns or more) DataFrames are.
Pandas is slowly growing new exentension types. Categoricals are the most popular, and the nullable integer type is already almost as popular as datetime with timezone.
More and better examples seem to be a high-priority development item. Pandas recently received a NumFOCUS grant to improve our documentation, which we're using to write tutorial-style documentation, which should help meet this need.
We also asked about specific, commonly-requested features.
Of these, the clear standout is "scaling" to large datasets. A couple observations:
- Perhaps pandas' documentation should do a better job of promoting libraries that provide scalable dataframes (like Dask, vaex, and modin)
- Memory efficiency (perhaps from a native string data type, fewer internal copies, etc.) is a valuable goal.
After that, the next-most critical improvement is integer missing values. Those were actually added in Pandas 0.24, but they're not the default, and there's still some incompatibilites with the rest of pandas API.
Pandas is a less conservative library than, say, NumPy. We're approaching 1.0, but on the way we've made many deprecations and some outright API breaking changes. Fortunately, most people are OK with the tradeoff.
Yes 94.89%
No 5.11%
Name: Is Pandas stable enough for you?, dtype: object
There's a perception (which is shared by many of the pandas maintainers) that the pandas API is too large. To measure that, we asked whether users thought that pandas' API was too large, too small, or just right.
Finally, we asked for an overall satisfaction with the library, from 1 (not very unsatisfied) to 5 (very satisfied).
Most people are very satisfied. The average response is 4.39. I look forward to tracking this number over time.
If you're analyzing the raw data, be sure to share the results with us @pandas_dev.


--- layout: post title: Delegate and Decorators tags: ---
After reading Object on Rails and some blog posts (like Thoughtbot’s one) I started playing with the Ruby’s delegate lib.
Let’s suppose I want to decorate an object, to wrap some instance methods. An simple inheritance from SimpleDelegator would to it
But now, let’s suppose I want to decorate and object and it’s class, to wrap some instance methods AND some class methods.
Like this pseudo code (It won’t work)
#UPDATE
Now, I got some tested code, deployed as gem if you want.
Check it out https://github.com/bltavares/delegate-class
I also found it useful to wrap ActiveRecord models and use the rails methods that require it to be an instance of ActievRecord, like #form_for
After playing with DelegateClass, I ended up with this <https://gist.github.com/1680411> code.
It works but I still don’t know if there is a real reason to use it.
But I’m happily playing with delegates. Maybe it is useful to someone (:


--- layout: page title: Response Format redirect_from: "/display/docs/Response+Format/" ---
Success responses are encoded into a generalized JSON structure with two basic properties: a response code, and a custom data object.
{
"response": {
"code": "SUCCESS",
"data": {
"localeId": "de-DE",
"lastModified": "[YYYY-MM-DDThh:mm:ssZ]"
}
}
}
Error responses include an array of errors, each with a key and message explaining the details of the error. Some errors may give additional details.
{
"response": {
"code": "VALIDATION_ERROR",
"errors": [{
"key": "parse.error",
"message": "There was a problem loading your file. No source strings found; Check your configuration http://goo.gl/OW6Q1o",
"details": {
"errorId": "cse8rqnf"
}
}]
}
}
| Value | Description | HTTP Code |
|---|---|---|
| SUCCESS | If the service request was processed normally | 200 |
| ACCEPTED | For file uploads, if the upload has begun but is taking more than a minute to complete, a 202 response is sent. | 202 |
| VALIDATION_ERROR | If something specific was wrong with the request parameters provided. One or more will describe the particular invalid parameter. | 400 |
| AUTHENTICATION_ERROR | If the provided credentials were not valid. | 401 |
| AUTHORIZATION_ERROR | Legacy error code from API | 401 |
| RESOURCE_LOCKED | The requested file is currently being processed by another operation. The file will be unlocked after the operation completes. See Upload for more details. | 423 |
| MAX_OPERATIONS_LIMIT_EXCEEDED | Too many simultaneous API requests per project or file. | 429 |
| GENERAL_ERROR | If an unexpected error occurred during the service request processing. | 500 |
| MAINTENANCE_MODE_ERROR | If Smartling has entered maintenance mode, all API services will return this error. After exiting maintenance mode all services should return to normal. | 503 |


{{ define "title" }}autodeb{{ end }} {{ define "content" }}
Take a look at our getting started guide on the home page.
Upload parameters are options associated with the uploads that you make to Autodeb. They are used to configure behaviours such as whether or not Autodeb should run Autopkgtests or if your upload should be forwarded to the ftp-master queue if all jobs succeed.
Upload parameters can be set in ~/.dput.cf by appending slash-separated key-value couples to the queue URL.
For example:
/upload
: no upload parameters are set, use defaults.
/upload/autopkgtest/true
: this sets autopkgtest to true.
/upload/forward_upload/false
: this sets forward_upload to false.
/upload/forward_upload/true/autopkgtest/false
: this sets
forward_upload to true and
autopkgtest to false.
This means that you could configure multiple autodeb hosts in ~/.dput.cf and select which to use depending on the situation:
[autodeb-forward]
# [...]
incoming = /upload/forward-upload/true
[autodeb]
# [...]
incoming = /upload
NOTE: dput uploads packages with a series of HTTP PUT requests. The only upload parameters that are considered are the ones that are set when uploading the .changes file.
deb [trusted=yes] {{ $.Data.RepositoryBaseURL }}/{{ $.Data.MainUpgradeRepositoryName }} autodeb main
This would work well with the with the following in /etc/apt/preferences.d/autodeb-package-upgrades:
Package: *
Pin: release a=autodeb
Pin-Priority: -10
One would then install packages from autodeb with apt-get install -t autodeb <package>
{{ end }}


CS140 Final Exam: December 7, 2004
Grading for Question 1
1.5 points per question. No partial credit.
Grading for Question 2
5 points per part. If you answered 7 or 9, or 24 even, you received 2 points
for part B.
Grading for Question 3
4 points for e. 3 points for n. 1 points for p.
0.5 point for i.
Grading for Question 4
3 points for the first part. 1 point for putting 2.5 in the correct
place initially. 1.5 for each of the rotations.
Grading for Question 5
5 points for part 1. You lost 2 if you had too many keys in the
internal nodes. You lost an extra one if you had incorrect keys.
For part 2, obviously, five points for a correct answer. Three points
for a correct tree with incorrect keys in the internal nodes. 2.5
points if you gave the "neighbor-stealing" solution with the correct
internal keys. 1.5 points if you gave the "neighbor-stealing" solution
with incorrect keys.
Grading for Question 6
- A recursive solution that has the right structure: 10 points
- Details correct: 5 points
Otherwise, it was qualitative for me to give partial credit.
Grading for Question 7
- Correct answer: 7 points.
- One to four incorrect characters: -1 per incorrect characters
- Newlines: -1
- Otherwise, you got some partial credit if I could figure out that
you were thinking something reasonable.


The primary penalty for breaches of conduct is a ban, which includes loss of trading privileges, forfeiture of registration fee, and immediate revocation of any unfilled orders.
Less drastic punitive measures such as a cool-down period may be considered for minor, first-time or infrequent conduct violations.


--- layout: post authors: ["Greg Wilson"] title: "Announcing November 2014 Lab Meeting" date: 2014-11-14 time: "07:00:00" tags: ["Lab Meeting"] ---
Our last online lab meeting for 2014 will be held at 10:00 am Eastern time on Thursday, December 4, and will be repeated at 7:00 pm Eastern on the same day. (We had originally planned to have it on November 27, but that would conflict with American Thanksgiving.) If you're planning to attend, please add yourself to the Etherpad at https://etherpad.mozilla.org/swc-labmeeting-2014-11 so that we have an idea of numbers. We look forward to seeing you in a few weeks.
And yes, we're calling it the November lab meeting even though it's in December, because it just wouldn't be programming without an off-by-one error...


--- layout: post title: Sending HTTP Requests without Reloading and without AJAX date: 2009-07-14 22:00:16.000000000 -07:00 type: post parent_id: '0' published: true password: '' status: publish categories: [] tags: - HTML - HTTP - HTTP Status Code - Programming - Servlet meta: _edit_last: '1' tmac_last_id: '166390243585560576' _jetpack_related_posts_cache: a:1:{s:32:"8f6677c9d6b0f903e98ad32ec61f8deb";a:2:{s:7:"expires";i:1543643438;s:7:"payload";a:3:{i:0;a:1:{s:2:"id";i:724;}i:1;a:1:{s:2:"id";i:165;}i:2;a:1:{s:2:"id";i:252;}}}} author: login: Philihp email<EMAIL_ADDRESS>display_name: Philihp first_name: '' last_name: '' ---
Supposing I have a simple HTML form that looks like this:
<form method="post" action="/SomeServlet"> <input type="text" name="message" value="Hello Server" /> <input type="submit" value="Send" /> </form>
And supposing I have a Servlet mapped at the path /SomeServlet, consisting of the code:
public class SomeServlet extends HttpServlet { protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { System.out.println(request.getParameter("message")); response.setStatus(HttpServletResponse.SC_NO_CONTENT); } }
If I goto the form, type in a message, and click the Send button, the message will print out on the Server's console. So What? So the cool thing is the HTML Form is not reloaded. Which could be useful if you've got heavy data on it. Seriously! Fire up Fiddler and watch your HTTP traffic.
Of course there are many other ways of doing this, a lot of them with Javascript or IFrames. This one does not require the use of anything fancy on the client side. Just an HTML Form. And of course it works outside of Java Servlets too-- so long as you can mess around with the HTTP status code.


There is a sample of 200 schools of Bogota distributed in 19 locations
The visualization is a "Pipe Chart" sorted by count of Schools on each location.
Summary [locations][Sector and types] [Types]
Tree [see all the schools] [collapsive the schools]


DeeDee's web design site
Index.html
This is my website This will have my projects for Computer science 1 course at CMIS
HOPE YOU ENJOYED YOUR BRIEF VISIT TO MY SITE


Alex Gignilliat
About
(current)
Portfolio
Contact
Download Resume
Contact
Name
Email address
Message
Submit


Tiarê Balbi Bonamini
A
software engineer
that can be described with just three words:
Enthusiastic about technology!
based in Ireland
Medium
Twitter
GitHub
Linkedin


Exercise 6
-
Write two functions, each which return a fixed number (different from each other) when called.
- Write an
add(..)
function that takes two numbers and adds them and returns the result. Call
add(..)
with the results of your two functions from (1) and print the result to the console.
- Write an
add2(..)
that takes two functions instead of two numbers, and it calls those two functions
and then sends those values to add(..)
, just like you did in (2) above.
- Replace your two functions from (1) with a single function that takes a value and returns a function back, where
the returned function will return the value when it's called.
- Write an
addn(..)
that can take an array of 2 or more functions, and using only
add2(..)
, adds them together. Try it with a loop. Try it without a loop (recursion). Try it with
built-in array functional helpers (map/reduce).
- Start with an array of odd and even numbers (with some duplicates), and trim it down to only have unique values.
- Filter your array to only have even numbers in it.
- Map your values to functions, using (4), and pass the new list of functions to the
addn(..)
from
(5).
- Bonus: write tests for your functions.


- test() - Method in class uncc.test.TestHSQLDatabaseConnection
-
- TestHSQLDatabaseConnection - Class in uncc.test
-
Test class for uncc.HSQLDatabaseConnection.
- TestHSQLDatabaseConnection() - Constructor for class uncc.test.TestHSQLDatabaseConnection
-
- TestISBN - Class in uncc.test
-
Test class for uncc.objects.ISBN and uncc.ISBNLookup.
- TestISBN() - Constructor for class uncc.test.TestISBN
-
- testISBN10CheckSum() - Method in class uncc.test.TestISBN
-
- testISBN10Conversion() - Method in class uncc.test.TestISBN
-
- testISBN13CheckSum() - Method in class uncc.test.TestISBN
-
- testISBN13Conversion() - Method in class uncc.test.TestISBN
-
- testISBNMatch() - Method in class uncc.test.TestISBN
-
- testNetworkISBN10Conversion() - Method in class uncc.test.TestISBN
-
- testNetworkISBN13Conversion() - Method in class uncc.test.TestISBN
-
- Timesheet - Class in uncc.objects
-
Object used to store a Tutor's availability.
- Timesheet() - Constructor for class uncc.objects.Timesheet
-
- toString() - Method in class uncc.objects.Book
-
- toString() - Method in class uncc.objects.HourRange
-
- Tutor - Class in uncc.objects
-
Object used to store information about a Tutor, their schedule, and their
course expertise.
- Tutor(String, String) - Constructor for class uncc.objects.Tutor
-
Constructor for the Tutor object.
- Tutor(String, String, Timesheet, String[]) - Constructor for class uncc.objects.Tutor
-
Constructor for the Tutor object.
- Tutor(String, String, Timesheet, String[], String) - Constructor for class uncc.objects.Tutor
-
Constructor for the Tutor object.
- Tutor(String[]) - Constructor for class uncc.objects.Tutor
-
Constructor for the Tutor object.
- Tutor(String[], Timesheet, String[]) - Constructor for class uncc.objects.Tutor
-
Constructor for the Tutor object.
- Tutor(String[], Timesheet, String[], String) - Constructor for class uncc.objects.Tutor
-
Constructor for the Tutor object.
- TutorTable - Class in uncc.tables
-
Java handler used to communicate with an HSQL Database Table that stores
Tutor objects.
- TutorTable(HSQLDatabaseConnection) - Constructor for class uncc.tables.TutorTable
-


Google One is the new subscription-based storage plan from Google and should not be compared to Google Drive. Basically, Google provides you with basic 15GB of storage that is distributed between your Gmail account, Google Photos, Drive and other services that company provides but if you want to access more storage then either you have to compress your files that might lose the originality of it or you have to delete the files, which is stupid. You can also access paid options which sound interesting in the world of cloud as it is much cheaper than to purchase extra HDD or SSD at higher rates. Google One comes to this point straight and that too with even lower charges for the same amount of storage.
From India's point of view, its key audience should be mid-range mobile holders who face the issue of storage with an internal memory of 32GB to 64GB and depends largely on cloud providers like Google or Microsoft for extra reliable storage. The beauty of it doesn't lie in its prices but the range it provides, it provides paid plans starting from 100GB at Rs.130/monthly at lowest to 30TB at Rs.19,500/monthly.I mean 30TB is enough for someone unless he plans to store more than 6million songs or 7500 movies or 9million photos on it. One is now available on Google Play Store where you can directly purchase plans, you can also access it through Web.
Fact of the week: PING stands for Packet InterNet Groper. It was first used in Submarines as acoustic sounds which can reach thousands of mile to detect objects in deep water.
What is new?
16Inch MacBook Pro.
16Inch Macbook Pro is the new member of the premium Macbook series. After its predecessor 15Inch release, Apple faced a lot of criticism about issues related to thermal throttling, butterfly keyboard and other undesirable aspects. So Apple decided to come back strong at the same rate with something everybody is talking about and that is 16Inch deal.
So what is so special right?
Now if you are an avid movie watcher or working photo designer, you seek to have a brilliant display to enjoy your stuff and here comes the bright 16Inch Retina display with P3 wide colour gamut and 500 nits of brightness.
Talking from the core, it has Intel Core i9 processor with 8 cores with 16 threads making it a super deal with not forgetting the desirable 64Gb DDR4 ram.
Now as Apple is not known for great gaming experiences but provides you par average performance with its AMD Radeon 5000 Pro MSeries with 8Gb VRAM creating hype around.
Let's address the butterfly in the room, finally a better keyboard with better response time and lesser sound surround time clicking it up.
Better battery life and high security is not a new feature to the series but thunderbolt 3 port worth praises from consumers providing with a flash speed of 40Gbps of transfer rate and supporting up to two 6K display.
So, in the end, it is the new beginning for a new improved Macbook series.


TROJAN EDDIE (director: Gillies MacKinnon; screenwriter: Billy Roche; cinematographer: John de Borman; cast: Richard Harris (John Power), Stephen Rea (Trojan Eddie), Brendan Gleeson (Ginger Power), Sean McGinley (Raymie), Angeline Ball (Shirley), Aislin McGuckin (Kathleen), Stuart Townsend (Dermot), Brid Brennan (Betty), Jason Gilroy (Patsy McDonagh), 1996-Ireland)
Reviewed by Dennis Schwartz
"Trojan Eddie" is a bleak and unsentimental portrait of a gypsy group in a small unnamed Irish town. John Power (Harris) is the 70-year-old, white-haired, gaunt faced, strong-armed patriarch to a gang of itinerant Irish gypsies, thieves, tinkers and unscrupulous salesmen known as travellers. He is mean-spirited and ornery.
The film is not a touristy tale; it is based on Irish folklore. The main problem it has, is that the story gets bogged down on unnecessary subplots, which make it difficult to focus entirely on the main story. It is seen through the eyes of a glib and talented salesman, known as Trojan Eddie (Rea), who can't handle things when he isn't hustling merchandise for the big boss, John Power. His private life is a mess. His ex-wife Shirley (Ball) is a tramp. She drops by his house needing a place to stay, which he generously agrees to, but she treats him with disdain, getting his ire when she taunts him that he might not be the father of the kids. He raises their two young daughters without her help, after he spent a year in prison for a bungled robbery, taking the full rap, not snitching on his weasel-like partner Rayme (McGinley).
 He is the only character that the audience can relate to in a kindly way, as this lowlife hustler, willing to cheat his friends and neighbors, might have some appeal and some might find him to be in a strange way, likable.
Harris is powerful as an old, prideful man, who can't forget how tough he was as a youth, not wanting to let go of his youth, easily wounded by any slur he imagines being cast against him. He is intimidating to everyone around him.  He tempts this itinerant girl with his possessions and asks her hand in marriage. After she accepts, while chaperoned home by Eddie and his partner, a kid about the age of Kathleen's, John's nephew Dermot (Townsend). The youngsters sneak off in the field and have sex, but John finds out about it, though he is not sure if Dermot or a boy he seen her talking to, Patsy McDonagh (Gilroy), was the culprit. But he still insists on the wedding.
At the wedding, the couple collect eleven thousand pounds for their dowry in a tin box, which Eddie brings into the house and gives to Kathleen. But she has other plans, as she runs away on her wedding night with Dermot and with the money, to the embarrassment of John. He immediately sends his men out looking for them. He also thinks Eddie might be a part of this, warning him that all will be forgiven if the girl comes back when she is ready and the money is returned intact.
The cast is top-notch, led by Harris's bone-chilling arrogant hoodlum portrayal, who can't stop bullying people. Rea is equally as good, in a role that is a take-off on the frenetic Crazie Eddie character who years ago was seen hawking goods on American TV. He is emotionally wrought at not being able to straighten his life out, and not till the very end of the film do we see him get some satisfaction from dealing with his bullying boss. The landscape reflected the hard life of its denizens. It showed the muddy roads of the rural Ireland community, their shany houses, the dingy buildings where the salesmen auctioned off the stolen goods, and the rotten attitude the itinerants had to the townies.
The actors brought life and passion to this morbid story of failed love, a failed love for both the young and the old. It is a story of how self-interest and thievery rule the day when all is said and done. A very scornful look at what some will do to get what they want or think they want. It is worth seeing for the tremendous performances and a bit of the gritty local flavor not usually seen about a film emanating from Ireland.
Written by Irish playwright Billy Roche and directed with verve by Gillies MacKinnon, whose last feature, Small Faces, was a coming of age tale set in the violence-ridden housing projects of Glasgow in the '60s.
REVIEWED ON 2/20/2000 GRADE: B-
Dennis Schwartz: "Ozus' World Movie Reviews"
http://www.sover.net/~ozus
<EMAIL_ADDRESS>© ALL RIGHTS RESERVED DENNIS SCHWARTZ
The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews


Sample setrun.py module for classic Clawpack¶
Warning
Need to update link? Add 2d example?
This sample setrun.py script is from the example in $CLAW/classic/tests/advection.
"""
Module to set up run time parameters for Clawpack.
The values set in the function setrun are then written out to data files
that will be read in by the Fortran code.
"""
import clawpack.clawutil.clawdata
#------------------------------
def setrun(claw_pkg='Classic'):
#------------------------------
"""
Define the parameters used for running Clawpack.
INPUT:
claw_pkg expected to be "Classic4" for this setrun.
OUTPUT:
rundata - object of class ClawRunData
"""
assert claw_pkg.lower() == 'classic', "Expected claw_pkg = 'classic'"
rundata = clawpack.clawutil.clawdata.ClawRunData(pkg=claw_pkg, num_dim=1)
#------------------------------------------------------------------
# Problem-specific parameters to be written to setprob.data:
#------------------------------------------------------------------
probdata = rundata.new_UserData(name='probdata',fname='setprob.data')
probdata.add_param('u', 1.0, 'advection velocity')
probdata.add_param('beta', 200., 'Gaussian width parameter')
#------------------------------------------------------------------
# Standard Clawpack parameters to be written to claw.data:
#------------------------------------------------------------------
clawdata = rundata.clawdata # initialized when rundata instantiated
# ---------------
# Spatial domain:
# ---------------
# Number of space dimensions:
clawdata.num_dim = 1
# Lower and upper edge of computational domain:
clawdata.lower[0] = 0.0
clawdata.upper[0] = 1.0
# Number of grid cells:
clawdata.num_cells[0] = 100
# ---------------
# Size of system:
# ---------------
# Number of equations in the system:
clawdata.num_eqn = 1
# Number of auxiliary variables in the aux array (initialized in setaux)
clawdata.num_aux = 0
# Index of aux array corresponding to capacity function, if there is one:
clawdata.capa_index = 0
# -------------
# Initial time:
# -------------
clawdata.t0 = 0.0
# Restart from checkpoint file of a previous run?
# Note: If restarting, you must also change the Makefile to set:
# RESTART = True
# If restarting, t0 above should be from original run, and the
# restart_file 'fort.chkNNNNN' specified below should be in
# the OUTDIR indicated in Makefile.
clawdata.restart = False # True to restart from prior results
clawdata.restart_file = 'fort.chk00006' # File to use for restart data
# -------------
# Output times:
#--------------
# Specify at what times the results should be written to fort.q files.
# Note that the time integration stops after the final output time.
# The solution at initial time t0 is always written in addition.
clawdata.output_style = 1
if clawdata.output_style == 1:
# Output nout frames at equally spaced times up to tfinal:
clawdata.num_output_times = 10
clawdata.tfinal = 1.0
clawdata.output_t0 = True # output at initial (or restart) time?
elif clawdata.output_style == 2:
# Specify a list of output times.
clawdata.tout = [0.5, 1.0] # used if output_style == 2
clawdata.num_output_times = len(clawdata.tout)
elif clawdata.output_style == 3:
# Output every iout timesteps with a total of ntot time steps:
clawdata.output_step_interval = 1
clawdata.total_steps = 5
clawdata.output_t0 = True
clawdata.output_format == 'ascii' # 'ascii' or 'netcdf'
clawdata.output_q_components = 'all' # could be list such as [True,True]
clawdata.output_aux_components = 'none' # could be list
clawdata.output_aux_onlyonce = True # output aux arrays only at t0
# ---------------------------------------------------
# Verbosity of messages to screen during integration:
# ---------------------------------------------------
# The current t, dt, and cfl will be printed every time step
# at AMR levels <= verbosity. Set verbosity = 0 for no printing.
# (E.g. verbosity == 2 means print only on levels 1 and 2.)
clawdata.verbosity = 1
# --------------
# Time stepping:
# --------------
# if dt_variable==1: variable time steps used based on cfl_desired,
# if dt_variable==0: fixed time steps dt = dt_initial will always be used.
clawdata.dt_variable = True
# Initial time step for variable dt.
# If dt_variable==0 then dt=dt_initial for all steps:
clawdata.dt_initial = 0.8 / float(clawdata.num_cells[0])
# Max time step to be allowed if variable dt used:
clawdata.dt_max = 1e+99
# Desired Courant number if variable dt used, and max to allow without
# retaking step with a smaller dt:
clawdata.cfl_desired = 0.9
clawdata.cfl_max = 1.0
# Maximum number of time steps to allow between output times:
clawdata.steps_max = 500
# ------------------
# Method to be used:
# ------------------
# Order of accuracy: 1 => Godunov, 2 => Lax-Wendroff plus limiters
clawdata.order = 2
# Use dimensional splitting?
clawdata.dimensional_split = 0
# For unsplit method, transverse_waves can be
# 0 or 'none' ==> donor cell (only normal solver used)
# 1 or 'increment' ==> corner transport of waves
# 2 or 'all' ==> corner transport of 2nd order corrections too
clawdata.transverse_waves = 0
# Number of waves in the Riemann solution:
clawdata.num_waves = 1
# List of limiters to use for each wave family:
# Required: len(limiter) == num_waves
# Some options:
# 0 or 'none' ==> no limiter (Lax-Wendroff)
# 1 or 'minmod' ==> minmod
# 2 or 'superbee' ==> superbee
# 3 or 'mc' ==> MC limiter
# 4 or 'vanleer' ==> van Leer
clawdata.limiter = ['mc']
clawdata.use_fwaves = False # True ==> use f-wave version of algorithms
# Source terms splitting:
# src_split == 0 or 'none' ==> no source term (src routine never called)
# src_split == 1 or 'godunov' ==> Godunov (1st order) splitting used,
# src_split == 2 or 'strang' ==> Strang (2nd order) splitting used, not recommended.
clawdata.source_split = 'none'
# --------------------
# Boundary conditions:
# --------------------
# Number of ghost cells (usually 2)
clawdata.num_ghost = 2
# Choice of BCs at xlower and xupper:
# 0 => user specified (must modify bcN.f to use this option)
# 1 => extrapolation (non-reflecting outflow)
# 2 => periodic (must specify this at both boundaries)
# 3 => solid wall for systems where q(2) is normal velocity
clawdata.bc_lower[0] = 2
clawdata.bc_upper[0] = 2
return rundata
# end of function setrun
# ----------------------
if __name__ == '__main__':
# Set up run-time parameters and write all data files.
import sys
if len(sys.argv) == 2:
rundata = setrun(sys.argv[1])
else:
rundata = setrun()
rundata.write()


Welcome to Minerva Salon, where all you need is here.
Our haircut artists are the best around the nation, experience the handcraft of the Goddesses.
Experience the best hair coloring and rebonding that even the Gods can't comprehend.

One of our professional hair stylists, he studied at Reyes International School of Cosmetology to hone his craft.
Our professional manicurist, she honed her craft at David Salon's Academy.
She is in charge of our desk and customer sign-up.
It is our goal to exceed your expectations. Come experience a family atmosphere where you come as guests and leave as friends. Our staff is highly trained with diversity in all aspects of Hair Cutting, Hair Treatment, and Manicures. We keep up on the latest trends in our industry by continually attending hair shows and education classes throughout the year. Come let us pamper you and provide you with quality services.


Input the coordinates (longitude, latitude) and the approximate date of the location you want to see from space.


Keshav Electricals is the premier solution provider and designer of lightning protection system and earthing.


This reference describes the default items that the template provides in a SKY UX single-page application.
-
.vscode folder — Contains two .json files to configure settings that are included for the developer's convenience.
-
coverage folder — Stores code coverage results for unit tests. This folder is generated when you run skyux test or skyux watch, and it provides a convenient way for developers to see what code the tests reached and what code they did not reach. We recommend that all new code should have 100 percent unit test code coverage. For information about the code coverage requirements to contribute to SKY UX, see the contribution guidelines.
-
dist folder — Contains files that are deployed through the continuous integration pipeline. This folder is generated when you run skyux build.
-
node_modules folder — Stores the external dependencies for SKY UX components and SKY UX Builder. This includes system files to build the single-page application. The folder is listed in the .gitignore file. Do not place it into source code control.
-
src folder — Contains the source files for the SPA.
-
app folder — Contains the files and folders for pages, components, and unit tests.
-
about folder — Contains the page, component, and unit test for the sample About page in the template SPA. The index.html file is required to generate a route, while the other .html file and the .ts file create the AboutComponent that index.html references. The .spec.ts file is the unit test for the component, and we recommend storing the unit test in the same location as the .ts file.
-
shared folder — The recommended location for components and services that are shared across an application. In the template project, the AppNavComponent creates the navigation menu.
-
app-extras.module.ts — Handles tasks such as registering providers and entry components. When this file exists, SKY UX Builder automatically imports it into the build process. For an example of how to register an entry component, see add an entry component.
-
app-sky.module.ts — Imports all of the SKY UX modules used throughout your SPA. This module is imported in the app-extras.module.ts file.
-
home.component.html, home.component.ts, home.component.spec.ts, and index.html — The page, component, and unit test for the sample Home page in the template SPA. The index.html file is required to generate a route, while the other .html file and the .ts file create the HomeComponent that index.html references. The .spec.ts file is the unit test for the component, and we recommend storing the unit test in the same location as the .ts file.
-
assets — Contains static assets such as images that you can reference throughout your SPA. For information on how to include static assets in HTML, CSS, and SCSS files, see the static assets tutorial.
-
.editorconfig — A configuration file to specify settings for editors that support an EditorConfig file to define and maintain consistent coding styles between editors and IDEs. For information about EditorConfig files, see the EditorConfig website.
-
.gitignore — A standard file for Git repositories that lists untracked files to intentionally ignore in the working directory. For information about gitignore files, see the Git documentation.
-
package.json — A configuration file for NPM to specify dependencies that are stored in the node_modules folder. For information about package.json files, see the NPM documentation.
-
README.md — A Markdown file for the repo to describe the SKY UX application.
-
skyuxconfig.json — A configuration file to specify settings for SKY UX applications. For information about these options, see the configuration options reference.
-
tsconfig.json — A configuration file for the TypeScript compiler. For information about tsconfig.json files, see the TypeScript documentation.
-
tslint.json — A configuration file for TSLint. For information about tslint.json files, see the TSLint documentation.


Deep links test for the isagenixdemo user. Please make sure that API has all these resources if something stopped working
Links to send within SMS (or any other app, which can't recognise a URI) - copy and send as a message
http://com.soundconcepts.apps.mybuildershare/action/view-all?market_id=2&asset_type=panel&tag=3.%20The%20Look%20Book
http://com.soundconcepts.apps.mybuildershare/action/contact?contact_id=4383997
http://com.soundconcepts.apps.mybuildershare/action/asset?asset_id=video_4610
Also, you should be able to test these links come from a web browser.
Asset test
Video 4610Contact test
Contact 4383997View All test
View all pdfsView All test, should show all assets, as tags are incorrect
View all pdfs, tag emptyView All test, should show all assets, as tags are incorrect
Media list - Zeroth tab in the appIncorrect tabs, should open a Media List
10th tab in the appSearch deep links
Specific asset pdf_38606


Reports
Guide your institution by understanding…
-
…the landscape
-
…how to respond
The Roadmap for Action
-
…the situation in 2020
2020 Update
Topics
Get actionable insights on key topics…
-
…interventions to make today
-
…the latest news
-
…underlying challenges
-
…the companies


2
The Mountain of the LORD
1 The word that Isaiah the son of Amoz saw concerning Judah and Jerusalem.
2 It shall come to pass in the latter days
that the mountain of the house of the LORD
shall be established as the highest of the mountains,
and shall be lifted up above the hills;
and all the nations shall flow to it,
3 and many peoples shall come, and say:
“Come, let us go up to the mountain of the LORD,
to the house of the God of Jacob,
that he may teach us his ways
and that we may walk in his paths.”
For out of Zion shall go the law,
and the word of the LORD from Jerusalem.
4 He shall judge between the nations,
and shall decide disputes for many peoples;
and they shall beat their swords into plowshares,
and their spears into pruning hooks;
nation shall not lift up sword against nation,
neither shall they learn war anymore.
5 O house of Jacob,
come, let us walk
in the light of the LORD.
The Day of the LORD
6 For you have rejected your people,
the house of Jacob,
because they are full of things from the east
and of fortune-tellers like the Philistines,
and they strike hands with the children of foreigners.
7 Their land is filled with silver and gold,
and there is no end to their treasures;
their land is filled with horses,
and there is no end to their chariots.
8 Their land is filled with idols;
they bow down to the work of their hands,
to what their own fingers have made.
9 So man is humbled,
and each one is brought low—
do not forgive them!
10 Enter into the rock
and hide in the dust
from before the terror of the LORD,
and from the splendor of his majesty.
11 The haughty looks of man shall be brought low,
and the lofty pride of men shall be humbled,
and the LORD alone will be exalted in that day.
12 For the LORD of hosts has a day
against all that is proud and lofty,
against all that is lifted up—and it shall be brought low;
13 against all the cedars of Lebanon,
lofty and lifted up;
and against all the oaks of Bashan;
14 against all the lofty mountains,
and against all the uplifted hills;
15 against every high tower,
and against every fortified wall;
16 against all the ships of Tarshish,
and against all the beautiful craft.
17 And the haughtiness of man shall be humbled,
and the lofty pride of men shall be brought low,
and the LORD alone will be exalted in that day.
18 And the idols shall utterly pass away.
19 And people shall enter the caves of the rocks
and the holes of the ground,
from before the terror of the LORD,
and from the splendor of his majesty,
when he rises to terrify the earth.
20 In that day mankind will cast away
their idols of silver and their idols of gold,
which they made for themselves to worship,
to the moles and to the bats,
21 to enter the caverns of the rocks
and the clefts of the cliffs,
from before the terror of the LORD,
and from the splendor of his majesty,
when he rises to terrify the earth.
22 Stop regarding man
in whose nostrils is breath,
for of what account is he?


@()
Minceraft, the game where you throw boats in a blender and then... wait, that's not right.
I meant Minecraft! The game where you mine and craft and mine and craft and mine and craft...
Ok enough with the silliness. Minecraft is awesome, and you should definatly check it out over at Minecraft.net


HazzelForms
Create, validate and mail PHP forms in minutes!
HazzelForms is a lightweight, PHP >= 7 based form framework. It helps developers to create, validate and send html forms with just a few lines of code while still providing flexibility for customisation.
HazzelForms uses HTML tags sparingly and does not include any CSS. Thus, it can easily be combined with grid systems like FlexBoxGrid, Bootsrap, material.io or any other grid system.
Example
More form with less code:
Demo form
Behind the scenes
require_once __DIR__ . '/HazzelForms/autoload.php';
$form = new HazzelForms\HazzelForm();
$form->addField('Demo name', 'text', ['placeholder' => 'Name']);
$form->addField('Demo email', 'email', ['placeholder' => 'E-Mail']);
$form->addField('Demo cat', 'dropdown', ['first' => '- Category -',
'options' => array(
'Manufacturing',
'Shipping',
'Human Resources'
)]);
if($form->validate()){
$form->sendMail('marketing@example.com');
}
$form->renderAll();


| Address Identicon | Address | Private Key (unencrypted) |
|---|---|---|
Bulk Generate Wallets
Number of Wallets To Generate
Generate Wallets
Generate WalletsSuccess! Your wallets have been generated.
**You need your Keystore File + password or Private
Key** to access this wallet in the future. Please save & back it up externally! There is no way to
recover a wallet if you do not save it. Read the [help page](https://www.MyTokenWallet.com/#help)
for instructions.


ethereumex v0.1.2 Ethereumex
Ethereumex
Elixir JSON-RPC client for the Ethereum blockchain
Installation
Add Ethereumex to your mix.exs
dependencies:
- Add
ethereumex
to your list of dependencies inmix.exs
:
def deps do
[{:ethereumex, "~> 0.1.2"}]
end
- Ensure
ethereumex
is started before your application:
def application do
[applications: [:ethereumex]]
end
Configuration
In config/config.exs
, add Ethereum protocol host params to your config file
config :ethereumex,
scheme: "http",
host: "localhost",
port: 8545
Usage
Available methods:
- web3_clientVersion
- web3_sha3
- net_version
- net_peerCount
- net_listening
- eth_protocolVersion
- eth_syncing
- eth_coinbase
- eth_mining
- eth_hashrate
- eth_gasPrice
- eth_accounts
- eth_blockNumber
- eth_getBalance
- eth_getStorageAt
- eth_getTransactionCount
- eth_getBlockTransactionCountByHash
- eth_getBlockTransactionCountByNumber
- eth_getUncleCountByBlockHash
- eth_getUncleCountByBlockNumber
- eth_getCode
- eth_sign
- eth_sendTransaction
- eth_sendRawTransaction
- eth_call
- eth_estimateGas
- eth_getBlockByHash
- eth_getBlockByNumber
- eth_getTransactionByHash
- eth_getTransactionByBlockHashAndIndex
- eth_getTransactionByBlockNumberAndIndex
- eth_getTransactionReceipt
- eth_getUncleByBlockHashAndIndex
- eth_getUncleByBlockNumberAndIndex
- eth_getCompilers
- eth_compileLLL
- eth_compileSolidity
- eth_compileSerpent
- eth_newFilter
- eth_newBlockFilter
- eth_newPendingTransactionFilter
- eth_uninstallFilter
- eth_getFilterChanges
- eth_getFilterLogs
- eth_getLogs
- eth_getWork
- eth_submitWork
- eth_submitHashrate
- db_putString
- db_getString
- db_putHex
- db_getHex
- shh_post
- shh_version
- shh_newIdentity
- shh_hasIdentity
- shh_newGroup
- shh_addToGroup
- shh_newFilter
- shh_uninstallFilter
- shh_getFilterChanges
- shh_getMessages
Examples
iex> Ethereumex.HttpClient.web3_client_version
{:ok,
%{"id" => 0, "jsonrpc" => "2.0",
"result" => "Geth/v1.6.5-stable-cf87713d/darwin-amd64/go1.8.3"}}
iex> Ethereumex.HttpClient.web3_sha3(["wrong_param"])
{:error,
%{"code" => -32602,
"message" => "invalid argument 0: missing 0x prefix for hex data"}}
iex> Ethereumex.HttpClient.eth_get_balance(["0x407d73d8a49eeb85d32cf465507dd71d507100c1", "latest"])
{:ok, %{"id" => 2, "jsonrpc" => "2.0", "result" => "0x0"}}
Note that all method names are snakecases, so, for example, shh_getMessages method has corresponding Ethereumex.HttpClient.shh_get_messages/1 method
Custom requests
Many Ethereum protocol implementations support additional JSON-RPC API methods. To use them, you should call Ethereumex.HttpClient.send_request/2 method.
For example, let’s call geth’s rpc_modules method.
iex> Ethereumex.HttpClient.send_request("rpc_modules")
{:ok,
%{"id" => 5, "jsonrpc" => "2.0",
"result" => %{"eth" => "1.0", "net" => "1.0", "rpc" => "1.0",
"web3" => "1.0"}}}
Contributing
- Fork it!
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request
Author
Ayrat Badykov (@ayrat555)
License
Ethereumex is released under the MIT License.
Link to this section Summary
Functions
Called when an application is started
Link to this section Functions
Called when an application is started.
This function is called when an the application is started using
Application.start/2
(and functions on top of that, such as
Application.ensure_started/2
). This function should start the top-level
process of the application (which should be the top supervisor of the
application’s supervision tree if the application follows the OTP design
principles around supervision).
start_type
defines how the application is started:
:normal
- used if the startup is a normal startup or if the application is distributed and is started on the current node because of a failover from another mode and the application specification key:start_phases
is:undefined
.{:takeover, node}
- used if the application is distributed and is started on the current node because of a failover on the nodenode
.{:failover, node}
- used if the application is distributed and is started on the current node because of a failover on nodenode
, and the application specification key:start_phases
is not:undefined
.
start_args
are the arguments passed to the application in the :mod
specification key (e.g., mod: {MyApp, [:my_args]}
).
This function should either return {:ok, pid}
or {:ok, pid, state}
if
startup is successful. pid
should be the PID of the top supervisor. state
can be an arbitrary term, and if omitted will default to []
; if the
application is later stopped, state
is passed to the stop/1
callback (see
the documentation for the c:stop/1
callback for more information).
use Application
provides no default implementation for the start/2
callback.
Callback implementation for Application.start/2
.


A stellar mass black hole could also be produced by the collapse of a neutron star or the merger of two compact objects. Not to be confused with a supermassive black hole, which are about a million times more massive and live in the centers of galaxies. There are about 60 stellar mass black holes known in X-ray binaries, but we only know the mass for about 18 of them (Corral-Santana et al. 2016). Most of them have masses of around 8M⊙.


The following snippet demonstrates how to request data from the Binance Crypto Future Price dataset:
def Initialize(self) -> None: self.SetBrokerageModel(BrokerageName.BinanceFutures, AccountType.Margin) self.SetBrokerageModel(BrokerageName.BinanceCoinFutures, AccountType.Margin) self.crypto_future_symbol = self.AddCryptoFuture("BTCBUSD", Resolution.Minute).Symbol
private Symbol _cryptoFutureSymbol; public override void Initialize { SetBrokerageModel(BrokerageName.BinanceFutures, AccountType.Margin); SetBrokerageModel(BrokerageName.BinanceCoinFutures, AccountType.Margin); // perpetual futures does not have a filter function _cryptoFutureSymbol = AddCryptoFuture("BTCBUSD", Resolution.Minute).Symbol; }


Hit and run driver kills two vigilante operatives in Anambra, guns removed
by Temisan AmoyeBy Vincent Ujumadu, Awka
Two members of Obosi Central Vigilante Group in Idemili North local government area of Anambra State yesterday lost their lives and their two pump action rifles taken away when suspected hoodlums hit them with their car at their duty post and fled after collecting their guns.
Anambra State Police Public Relations Officer, PPRO, Mr. Haruna Mohammed, who confirmed the incident said the victims, Chibuzor Nwobodo and Chidebe Ohaeri were working at Oduzor along Obosi –Nkpor road when the incident happened.
ALSO READ: Anambra acquires land for honey production, export — ADP Manager
According to him, one Chidebe Emodi, said to be the commander of the Obosi Central Vigilante Group reported the matter at Obosi Division of the Nigeria Police Force.
Haruna said: “The victims were allegedly knocked down by a hit and run Toyota Avalon car and two of their pump action guns, Mossberg P990624 and Federal manual 15-1317, carted away to an unknown destination.
“The scene was visited by Police patrol team led by the Divisional Police Officer, DPO, for Obosi, CSP Usman Ibrahim and victims were rushed to Chukwurah Hospital, Obosi where they were confirmed dead by the medical doctor.” No arrest had however been made at the time of filing this report.
ALSO READ: Court annuls sack of FUOYE’s Lecturer, orders immediate reinstatement
The PPRO said the corpses have been deposited at Edward Mortuary, Obosi for autopsy, adding that the Anambra State Commissioner of Police, Mr. John Abang had also ordered for a discreet investigation to ascertain circumstances surrounding the incident with a view to bringing the perpetrators to justice.


Full name:
org.devzendo:cross-platform-launcher-plugin:1.3.0:createlauncher
Description:
Attributes:
| Name | Type | Since | Description |
|---|---|---|---|
| <applicationName> | String | - | The name of the application for whom this launcher is to be
generated. On Mac OS X, this is used to name the application menu.
On Windows, this is used to name the Janel .exe/.lap files. If not
specified the client project's artifact id will be used. Default value is: ${xplp.applicationname}. |
| <mainClassName> | String | - | The fully-qualified name of the main class of your application,
i.e. contains a public static void main... Default value is: ${xplp.mainclassname}. |
| <os> | String | - | The OS to generate a launcher for: Windows, MacOSX or Linux. Default value is: ${xplp.os}. |
| Name | Type | Since | Description |
|---|---|---|---|
| <bundleOsType> | String | - | Mac OS X only: The bundle OS type. This is registered in the Mac OS
X Info.plist as CFBundleTypeOSTypes. Default value is: ${xplp.bundleostype}. |
| <bundleSignature> | String | - | Mac OS X only: The bundle signature. Only use this if you have a
registered creator code. This is registered in the Mac OS X
Info.plist as CFBundleSignature, and in the PkgInfo prefixed with
APPL As stated at the Apple developer website "This is a simple text file that contains the string APPL optionally concatenated with a four letter creator code. If an application does not have a registered creator code, the string APPL???? should be used." Default value is: ${xplp.bundlesignature}. |
| <bundleTypeName> | String | - | Mac OS X only: The bundle type name This is registered in the Mac
OS X Info.plist as CFBundleTypeName. Default value is: ${xplp.bundletypename}. |
| <fileType> | String | - | Mac OS X only: Any file type that is associated with this
application. This is registered in the Mac OS X Info.plist as
CFBundleTypeExtensions. Default value is: ${xplp.filetype}. |
| <iconsFileName> | String | - | Mac OS X only: The name of the icons file. Default value is: ${xplp.iconsfilename}. |
| <janelBits> | String | - | Windows only: If using the Enhanced Janel, are you using 32- or
64-bit? The original Janel makes no such distinction. Can be "32"
or "64". The default is "64" as 32-bit systems are becoming rarer. Default value is: ${xplp.janelbits}. |
| <janelCustomLines> | String[] | - | Windows only: A list of lines of text that will be added to the
Janel launcher file. Default value is: ${xplp.janelcustomline}. |
| <janelDirectory> | String | - | Windows only: Should the Janel .EXE, .DLL and .LAP file be in the
root directory (the backwards-compatible default), or in a 'bin'
directory? This affects the path to the library directory in the
.LAP file - if "root", we can refer to the library directory as
"lib", but if the .LAP file is in a "bin" directory, then the path
to the library directory would be "../lib". Can be "root" or "bin".
The default is "root" for backwards compatibility. Default value is: ${xplp.janeldirectory}. |
| <janelType> | String | - | Deprecated. Use launcherType instead. Default value is: ${xplp.janeltype}. |
| <janelVersion> | String | - | Windows only: The (major/minor) version of Janel you wish to use to
launch your program. Choices are: The Original Janel 3.0.2 by
Timothy D. Kil that's been discontinued. The Enhanced Janel
4.2.0-98 continued by Michael Knigge. Both versions of Janel are
embedded in the plugin; if you are using the Enhanced version, also
consider setting the xplp.janelbits property. Can be "3.0"
(currently 3.0.2) or "4.2" (currently 4.2.0-98). The default is
"3.0" for backwards compatibility. Default value is: ${xplp.janelversion}. |
| <launcherType> | String | - | The launcher type, can be "Console" or "GUI". For Windows, whether
to use the Console or GUI Janel EXE. For Mac OS X, whether to
create a script or .app structure. Default value is: ${xplp.launchertype}. |
| <libraryDirectory> | String | - | The directory where the application's jars are. By default, assume
lib/ Default value is: ${xplp.librarydirectory}. |
| <narClassifierTypes> | String[] | - | A list of NAR (Native ARchive, from the Maven NAR Plugin)
classifiers and types. These refer to native library files that
have been unpacked using the nar-download, nar-unpack and
nar-assembly goals of the Maven NAR Plugin, and reside in the
target/nar/lib/classifier/type directories. Any files in these directories will be copied to the launcher's library directory. The params you specify here must be in the form classifier:type, e.g. x86_64-MacOSX-g++:jni and you may specify as many as you like; only those directories that have anything in them will have their contents copied. Default value is: ${xplp.narClassifierType}. |
| <outputDirectory> | File | - | The directory into which the output files will be placed. By
default, this is the target directory. The launcher directory
structure will be created in a subdirectory of this. This
subdirectory will be named according to the platform specified in
the os parameter, so: windows, linux or macosx. Default value is: ${project.build.directory}. |
| <stubType> | String | - | Mac OS X GUI launchers only: whether to use Apple's
JavaApplicationStub, or Tobias Fischer's universal application
stub. (Currently this Maven plugin supplies v2.1.0 of Tobias' stub)
Please see https://github.com/tofi86/universalJavaApplicationStub
for details of this. If you want to launch with something other
than Apple Java 6, you need the universal stub. Can be "Apple" or
"Universal". Default is "Apple" for backwards compatibility. Default value is: ${xplp.stubtype}. |
| <systemProperties> | String[] | - | A list of system properties, to be passed to the JVM via multiple
-Dxxx=yyy parameters. When specifying system properties, omit the
-D, and just give them as xxx=yyy. The platform-specific launcher
will add in the -D if necessary. Default value is: ${xplp.systemproperty}. |
| <vmArguments> | String[] | - | A list of VM arguments, to be passed straight to the JVM, e.g.
-Xmx2048. Note that on Mac OS X, your application should set
-Xdock:name=MyApplication to have the correct name in the
application menu and on the dock. Default value is: ${xplp.vmargument}. |


Service
You have choices
Easy Integration
Setup your username, company, and location(s) and forward your vCheck emails for quick and easy integration
API
A full REST API is available to customize your health checks
Consultants
Our partner company Lockstep can customize Powershell scripts to suit your needs.
Options
Find yourself in a situation where you cannot use a hosted solution? Fork Sendash on Github and host it internally for free! Blocks of time can be purchased to support your needs if you do not have a development shop.
Contact
Leave a Message
Contact Us
sales@sendash.com