Skip to content

Instantly share code, notes, and snippets.

View washingtonsoares's full-sized avatar
🎯
Focusing

Washington Soares washingtonsoares

🎯
Focusing
View GitHub Profile
angular
.module('ionicApp.state.CampaingCategoryController', [])
.controller('CampaingCategoryController', function ($scope, CampaingCategoryFactory) {
var initialize = function(){
CampaingCategoryFactory.categories().then(function(data){
$scope.categories = data;
console.log($scope.categories);
console.log("\n");
}, function(){
angular
.module('ionicApp.state.CampaingCategoryController', [])
.controller('CampaingCategoryController', ['$scope','CampaingCategoryFactory', function ($scope, CampaingCategoryFactory) {
console.log('CampaingCategoriesController loaded');
// CampaingCategoryFactory.hello();
// CampaingCategoryFactory.categories();
// CampaingCategoryFactory.category();
$scope.categories = CampaingCategoryFactory.categories().then(function(data){
-Dspring.profiles.active=development -Xmx2048m -XX:MaxPermSize=512M -DAPPLICATION_VERSION=0.0.1-1
qtd_numero_iguais :: Int -> Int -> Int -> Int
qtd_numero_iguais a b c = if (a == b && b==c) then 3 else if (a==b || b ==c || a==c) then 2 else 0
--b*b > 4*a*c
duas_raizes a b c = b*b > 4*a*c
--b*b == 4*a*c
uma_raiz a b c = b*b == 4*a*c
--b*b < 4*a*c
nenhuma_raiz a b c = b*b < 4*a*c
set global sql_mode='STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION';
{-|
1)
> 7 `div` 2:
3
> 7 `div` 2 == div 7 2
True
> (*) ((+) 7 2) 7
63
> (+1) 3
4
public class JavaApplication1 {
static int i = 3;
public static void main(String[] x) {
for(new JavaApplication1().i = 10;new JavaApplication1().i < 100;new JavaApplication1().i++){
System.out.println(i);
}
}
var http = require('http');
//The url we want is: 'www.random.org/integers/?num=1&min=1&max=10&col=1&base=10&format=plain&rnd=new'
var options = {
host: 'api.postmon.com.br',
path: '/v1/rastreio/ect/PI939559055BR'
};
callback = function(response) {
var str = '';
@washingtonsoares
washingtonsoares / database.yml
Created March 4, 2016 00:50 — forked from danopia/database.yml
Default SQLite database.yml
# SQLite version 3.x
# gem install sqlite3-ruby (not necessary on OS X Leopard)
development:
adapter: sqlite3
database: db/development.sqlite3
pool: 5
timeout: 5000
# Warning: The database defined as "test" will be erased and
# re-generated from your development database when you run "rake".
# MySQL. Versions 4.1 and 5.0 are recommended.
#
# Install the MySQL driver:
# gem install mysql2
#
# And be sure to use new-style password hashing:
# http://dev.mysql.com/doc/refman/5.0/en/old-client.html
development:
adapter: mysql2
encoding: utf8