This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var MyClass = (function () { | |
| // private static | |
| var nextId = 1; | |
| // constructor | |
| var cls = function () { | |
| // private | |
| var id = nextId++; | |
| var name = 'Unknown'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| grafo = { | |
| '0': ['6'], | |
| '1': ['2', '6'], | |
| '2': ['1', '3', '7'], | |
| '3': ['2'], | |
| '4': ['3', '5'], | |
| '5': ['4', '10'], | |
| '6': ['0', '1', '7'], | |
| '7': ['6', '12', '13'], | |
| '8': ['3', '7', '9', '13'], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Atom sync configs |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package br.com.vndmtrx.android.myapplication.util; | |
| import java.lang.annotation.ElementType; | |
| import java.lang.annotation.Retention; | |
| import java.lang.annotation.RetentionPolicy; | |
| import java.lang.annotation.Target; | |
| @Retention(RetentionPolicy.RUNTIME) | |
| @Target(ElementType.FIELD) | |
| public @interface LoadView { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package br.com.vndmtrx.android.myapplication; | |
| import android.content.Intent; | |
| import android.support.v7.app.AppCompatActivity; | |
| import android.os.Bundle; | |
| import android.widget.RelativeLayout; | |
| import android.widget.TextView; | |
| public class DisplayMsg extends AppCompatActivity { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| *filter | |
| :INPUT DROP [0:0] | |
| :FORWARD DROP [0:0] | |
| :OUTPUT ACCEPT [0:0] | |
| :Invalid - [0:0] | |
| :Accepted - [0:0] | |
| :Prohibited - [0:0] | |
| :Allow - [0:0] | |
| :Finish - [0:0] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Option Explicit | |
| 'Código VBS para salvar a chave do Sistema para Windows 10, 8 e 7. | |
| 'Adaptado do site: http://winaero.com/blog/how-to-view-your-product-key-in-windows-10-windows-8-and-windows-7/ | |
| Dim objshell, Caminho, ChaveDigitalProduto, Result | |
| Set objshell = CreateObject("WScript.Shell") | |
| 'Registra o path do registro onde está a chave do sistema | |
| Caminho = "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\" | |
| 'Chave de registro do sistema |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <future> | |
| using namespace std; | |
| template <typename Fn, typename... Args> | |
| auto do_async_with_log(ostream& os, Fn&& fn, Args&&... args) | |
| -> future<decltype(fn(args...))> | |
| { | |
| os << "[TID=" << this_thread::get_id() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| def fizzbuzz(x): | |
| a = 0 if x % 3 else 1 | |
| a += 0 if x % 5 else 2 | |
| return ("{0}", "Fizz", "Buzz", "FizzBuzz")[a].format(x) | |
| list(map(fizzbuzz, range(1, 101))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| list(map(lambda x: ("FizzBuzz", "{0}", "{0}", "Fizz", "{0}", "Buzz", | |
| "Fizz", "{0}", "{0}", "Fizz", "Buzz", "{0}", "Fizz", | |
| "{0}", "{0}")[x%15].format(x), range(1, 101))) |