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
| const numeros = [3, 23, 12]; | |
| numeros.sort(function(a, b){return a - b}); // --> 3, 12, 23 |
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
| const numeros = [3, 23, 12]; | |
| numeros.sort(); // --> 12, 23, 3 |
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 ciudades = ['Pachuca','Chilpancingo','Zapopan', 'Acapulco', 'Ciudad Madero', 'Cuernavaca']; | |
| console.log(ciudades.sort()); | |
| //resultado: ["Acapulco", "Chilpancingo", "Ciudad Madero", "Cuernavaca", "Pachuca", "Zapopan"] |
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
| select [dbo].[DiasLaborales]('2021-03-02','2021-03-19') | |
| --Resultado: 14 |
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
| CREATE FUNCTION [dbo].[DiasLaborales] | |
| (@FechaInicial DATE, | |
| @FechaFinal DATE ) | |
| RETURNS INT | |
| AS | |
| BEGIN | |
| DECLARE @fecha DATE | |
| DECLARE @diaslaborales int |
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
| export class AppComponent implements OnInit { | |
| constructor(private httpClient: HttpClient) { | |
| } | |
| private config: {version: string}; | |
| ngOnInit() { | |
| this.config = require("./../assets/config.json"); | |
| console.log(this.config.version); | |
| const headers = new HttpHeaders() | |
| .set('Cache-Control', 'no-cache') |
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
| export class AppComponent implements OnInit { | |
| constructor(private httpClient: HttpClient) { | |
| } | |
| private config: {version: string}; | |
| ngOnInit() { | |
| this.config = require("./../assets/config.json"); | |
| console.log(this.config.version); | |
| const headers = new HttpHeaders() | |
| .set('Cache-Control', 'no-cache') |
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
| export class AppComponent implements OnInit { | |
| private config: {version: string}; | |
| ngOnInit() { | |
| this.config = require('./../assets/config.json'); | |
| console.log(this.config.version); | |
| } | |
| } |
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
| { | |
| "version":"1.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
| var dias = ['lunes','martes','miércoles','jueves','viernes']; | |
| var diasMayusculas = dias.map(function(dia){ | |
| return dia.toUpperCase(); | |
| }); | |
| console.log(diasMayusculas); //resultado: ["LUNES", "MARTES", "MIÉRCOLES", "JUEVES", "VIERNES"] |