Coder Social home page Coder Social logo

challenge-ns2's Introduction

1º Challenge

Requirements

  • Docker
  • Java 8
  • Postman

Deployment

After installed "Requirements" enter the project folder and run the following command.

$ docker run -it -d -p 27017:27017 mongo

and running application Java

Tests routes API via Postman

APIs endpoints

GET http://localhost:8080/client [lista todos os clientes]

GET http://localhost:8080/client/{id} [lista um cliente por ID]

POST http://localhost:8080/client [cadastra um novo cliente]

PUT http://localhost:8080/client/{id} [atualiza os dados de um cliente]

DELETE http://localhost:8080/client/{id} [remove um cliente por ID]

2º Challenge

import java.util.Scanner;

public class Telefone {

    public static void main(String[] args) {

        System.out.println("Digite seu telefone.");
        Scanner scanner = new Scanner(System.in);

       String TEL = scanner.next();

        scanner.close();
      
        System.out.println("Seu telefone: " + "(" + TEL.substring(0, 2) + ")" + TEL.substring(2, 7) + "-" + TEL.substring(7, 11));
    }
}

3º Challenge

SELECT DESC_PRODUTO, COUNT(*) QUANTIDADE FROM #ITENS_PEDIDOS_TESTE A
INNER JOIN #PEDIDOSTESTE B ON A.COD_PEDIDO = B.COD_PEDIDO 
GROUP BY DESC_PRODUTO HAVING COUNT(*) > 1

4º Challenge

db.produto.find({"descricao": {$regex: /Alemanha/}})

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.