Consider this contrived example of string manipulation. We want to convert a string to uppercase
and append "!"
.
Procedural style code:
function test(str) {
return str.toUpperCase() + "!";
}
call plug#begin() | |
Plug 'pangloss/vim-javascript' | |
Plug 'leafgarland/typescript-vim' | |
Plug 'gregsexton/MatchTag' | |
Plug 'bling/vim-airline' | |
Plug 'tpope/vim-projectionist' | |
Plug 'vim-scripts/HTML-AutoCloseTag' | |
Plug 'tpope/vim-endwise' | |
Plug 'google/vim-searchindex' |
$(function() { | |
console.log('now running'); | |
var canvas = document.querySelector('#canvas'); | |
var ctx = canvas.getContext('2d'); | |
var h = 150; | |
var w = 300; | |
var start = 0.0; | |
var radius = 0; |
package com.sample.test | |
import java.io.IOException; | |
import javax.servlet.ServletConfig; | |
import javax.servlet.ServletException; | |
import javax.servlet.ServletOutputStream; | |
import javax.servlet.http.HttpServlet; | |
import javax.servlet.http.HttpServletRequest; | |
import javax.servlet.http.HttpServletResponse; |
const R = require('ramda'); | |
/* | |
* https://cryptopals.com/sets/1/challenges/1 | |
*/ | |
const HEX_DIGITS = [ "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "A", "B", "C", "D", "E", "F" ]; | |
const HEX_TO_BINARY_MAP = { | |
"0": "0000", | |
"1": "0001", |
hardstatus alwayslastline | |
#hardstatus string "%{= g} %{= w}%-Lw%{=r}%n%f* %t%{-}%+LW" | |
hardstatus string '%{= kG}[%{G}%H%? %1`%?%{g}][%{= kw}%-w%{+b yk} %n*%t%?(%u)%? %{-}%+w %=%{g}][%{B}%m/%d %{W}%C%A%{g}]' | |
defscrollback 5000 | |
bindkey "^x" remove | |
bind x remove | |
bind l focus right | |
bind h focus left |
$ java -version
$ mvn -version
$ mvn archetype:generate -DgroupId=com.mycompany.app -DartifactId=my-app -DarchetypeArtifactId=maven-archetype-quickstart -DinteractiveMode=false
$> brew install cntlm
Ream more about CNTLM here: http://cntlm.sourceforge.net/
Username <eid>
Domain