#(Quase) Tudo que você precisa saber sobre objetos em Javascript
Roteiro
- Javascript é sobre objetos
- Declaração
- Propriedades e descritores
- Métodos e o this
- Notação literal
- Herança e protótipos
| port module Spelling exposing (..) | |
| import Html exposing (..) | |
| import Html.Events exposing (..) | |
| import String | |
| main = | |
| program | |
| { init = init |
| #include <stdlib.h> | |
| #include <string.h> | |
| void failure(char* pattern, int* f); | |
| int kmp(char* t, char* p); | |
| int* init_array(int size) { | |
| int* arr = (int*)malloc(size * sizeof(int)); | |
| int i; | |
| for(i = 0; i < size; i++) { |
| port module Spelling exposing (..) | |
| import Html exposing (..) | |
| import Html.App as App | |
| import Html.Attributes exposing (..) | |
| import Html.Events exposing (..) | |
| import String | |
| main = |
| package com.stackoverflow.q3732109; | |
| import java.io.IOException; | |
| import java.io.OutputStream; | |
| import java.net.InetSocketAddress; | |
| import com.sun.net.httpserver.HttpExchange; | |
| import com.sun.net.httpserver.HttpHandler; | |
| import com.sun.net.httpserver.HttpServer; |
| #!/bin/bash | |
| # Record from mic | |
| arecord -d 3 -f cd -t wav -r 16000 -c 1 -D pulse test.wav | |
| # Get record volume | |
| sox test.wav -n stats -s 16 2>&1 | grep 'Max level' | awk '{print $3}' | |
| # Convert to flac for smaller footprint | |
| flac -f test.wav | |
| # Google speech recognition | |
| LANG=en-us |
#(Quase) Tudo que você precisa saber sobre objetos em Javascript
Roteiro
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <title> </title> | |
| <link rel="stylesheet" type="text/css" href="http://cdn.jsdelivr.net/min/1.5/min.min.css"> | |
| <style> | |
| body,textarea,input,select { | |
| background:0; | |
| border-radius:0; | |
| font:16px sans-serif; |
| import React from 'react'; | |
| let lastScrollY = 0; | |
| let ticking = false; | |
| class App extends React.Component { | |
| componentDidMount() { | |
| window.addEventListener('scroll', this.handleScroll, true); | |
| } |
| var path = require('path') | |
| var childProcess = require('child_process') | |
| var phantomjs = require('phantomjs') | |
| var nodemailer = require("nodemailer"); | |
| // create reusable transport method (opens pool of SMTP connections) | |
| var smtpTransport = nodemailer.createTransport("SMTP",{ | |
| service: "Gmail", | |
| auth: { | |
| user: "br****@gmail.com", |
Automated analysis is the main advantage to working with a modern statically typed compiled language like C++. Code analysis tools can inform us when we have implemented an operator overload with a non-canonical form, when we should have made a method const, or when the scope of a variable can be reduced.