somatária de 1
à n
= somatoria(n)
Para n
par
para n = 6
temos:
somatoria(6) = 1 + 2 + 3 + 5 + 6
2 + 5 = 7
+-----------+
public int somaNumPares(int[] A) { | |
int i = 0; | |
int soma = 0; | |
int n = A.length; | |
while(i < n) { | |
if(A[i] % 2 == 0) | |
soma = soma + A[i]; | |
i++; | |
} |
public class Main { | |
public static void main(String[] args) throws Exception { | |
MinioClient minioClient = new MinioClient("http://localhost:9000", "minotestkey", "miniotestsecret"); | |
minioClient.makeBucket("test-bucket"); | |
} | |
} |
{"swagger":"2.1","info":{"version":"v1","title":"Dead Code Detection Service","contact":{"name":"Wellington Pinheiro"}},"basePath":"/api","tags":[{"name":"Repository controller"}],"schemes":["http","https"],"paths":{"/repository":{"get":{"tags":["Repository controller"],"summary":"List all repositories analyzed. This is a simplified view of repository without the code smells.","description":"","operationId":"getRepositories","consumes":["application/json"],"produces":["application/json"],"parameters":[],"responses":{"200":{"description":"Zero or more repositories found"}}},"post":{"tags":["Repository controller"],"summary":"Create a repository.","description":"","operationId":"addRepository","consumes":["application/json"],"produces":["application/json"],"parameters":[{"in":"body","name":"body","description":"Repository to be added and analyzed. The supported languages are:JAVA, ADA, CPP and FORTRAN","required":false,"schema":{"$ref":"#/definitions/RepositoryRequest"}}],"responses":{"200":{"description":"The |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>FormData, Node and Formidable Example</title> | |
</head> | |
<body> | |
<button onClick="buttonClicked()">Click me</button> | |
<script src="https://code.jquery.com/jquery-3.1.1.js"></script> | |
<script type="text/javascript" charset="utf-8" async defer> |
import java.util.ArrayDeque; | |
import java.util.Deque; | |
class TopologicalSort { | |
static final int NUM_VERTEXES = 7 | |
void applyTopologicalSortLocally(Graph g, Integer vertex, Set<Integer> visited, Deque<Integer> stack) { | |
visited.add(vertex) | |
g.getAdjacentVertexes(vertex).each { adjVertex -> | |
if (!visited.contains(adjVertex)) { |
somatária de 1
à n
= somatoria(n)
Para n
par
para n = 6
temos:
somatoria(6) = 1 + 2 + 3 + 5 + 6
2 + 5 = 7
+-----------+
This is a small guide that aims you to learn some Node JS and, of course, Javascript! This is not a reference nor a detailed guide, it's just a start up point.
In the begining there were HTML. I was funny, but not that funny, because it was...static! We were not able deal with most user interations only with HTML. Then something happened which unleashed the power of our imagination...we learned to talk! No, it's not that! Then JS appeared to make our applications more attractive! With JS we were able to break the limitations imposed by the static HTML and now we live in a world of dynamic content. Note that everything we talked is related to JS running in the browser context, something that we call client side JS.
As time gone by, people have increased their interest in JS, due to its easyness, and started thinking: wouldn't this JS able to run on the server side either? And then something happened which unleashed...yes, then Node JS came in!
brew tap caskroom/cask
brew install brew-cask
brew cask install java
import React from 'react' | |
import { render } from 'react-dom' | |
var ProductCategoryRow = React.createClass({ | |
render: function() { | |
return (<tr><th colSpan="2">{this.props.category}</th></tr>); | |
} | |
}); | |
var ProductRow = React.createClass({ |
public class TwoLoopsWithObjects { | |
public static void main(String[] args) { | |
StringBuilder sb = new StringBuilder(); | |
Integer i = new Integer(0); | |
Integer max = new Integer(100000); | |
while (i.intValue() < 100000) { | |
Integer j = i; | |
long start = System.nanoTime(); |