- Like C, but with garbage collection, memory safety, and special mechanisms for concurrency
- Pointers but no pointer arithmetic
- No header files
- Simple, clean syntax
- Very fast native compilation (about as quick to edit code and restart as a dynamic language)
- Easy-to-distribute executables
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<file-input v-model="filename" @formData="formData"> | |
<v-btn @click.native="uploadFiles"> | |
</template> | |
<script> | |
import fileInput from './file-input.vue' | |
export default{ | |
components:{fileInput} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.math.BigInteger; | |
import java.nio.charset.Charset; | |
import java.security.MessageDigest; | |
import java.util.Random; | |
import javax.crypto.Cipher; | |
import javax.crypto.spec.IvParameterSpec; | |
import javax.crypto.spec.SecretKeySpec; | |
import org.apache.commons.codec.binary.Base64; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.qinti.eptp.util; | |
/** | |
* Created by adildramdan on 5/6/15. | |
*/ | |
/** | |
* This class will convert numeric values into an english representation | |
* <p> | |
* For units, see : http://www.jimloy.com/math/Milyar.htm |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Number.prototype.pad = function(size) { | |
var s = String(this); | |
while (s.length < (size || 2)) {s = "0" + s;} | |
return s; | |
} | |
(1).pad(3) // => "001" | |
(10).pad(3) // => "010" | |
(100).pad(3) // => "100" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div ng-app="MyApp"> | |
<h1>Zero padding filter</h1> | |
<div> | |
<input type="text" ng-model="ztext" placeholder="Type some text ..." /> | |
</div> | |
<div> | |
<h2>Result:</h2> | |
<p>{{ztext | zpad:4}}</p> | |
</div | |
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$("#selectBox").append('<option value="option6">option6</option>'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [ "$#" -ne 1 ] ; then | |
echo "Usage: $0 <title>" >&2 | |
exit 1 | |
fi | |
title=`echo "$1" |sed 's/ /-/g'` | |
fileName="_posts/`date +%Y-%m-%d-$title.markdown`" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Groovy also has a Time Category class which gives you DSL style syntax for manipulating dates. Here is an example: | |
import org.codehaus.groovy.runtime.TimeCategory | |
now = new Date() | |
println now | |
use(TimeCategory) { | |
footballPractice = now + 1.week - 4.days + 2.hours - 3.seconds | |
} | |
println footballPractice | |
which will produce output like this: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<databaseChangeLog | |
xmlns="http://www.liquibase.org/xml/ns/dbchangelog" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xmlns:ext="http://www.liquibase.org/xml/ns/dbchangelog-ext" | |
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-2.0.xsd | |
http://www.liquibase.org/xml/ns/dbchangelog-ext http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-ext.xsd"> | |
</databaseChangeLog> |
NewerOlder