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
import React, { Component } from 'react'; | |
import logo from './logo.svg'; | |
import './App.css'; | |
class App extends Component { | |
render() { | |
return ( | |
<div className="App"> | |
<header className="App-header"> | |
<img src={logo} className="App-logo" alt="logo" /> |
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
<h2>Hero List</h2> | |
<p><i>Pick a hero from the list</i></p> | |
<ul> | |
<li *ngFor="let hero of heroes" (click)="selectHero(hero)"> | |
{{hero.name}} | |
</li> | |
</ul> | |
<app-hero-detail *ngIf="selectedHero" [hero]="selectedHero"></app-hero-detail> |
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
import numpy | |
import cv2 | |
imagen = cv2.imread("tacos.jpg") | |
cv2.imshow("ventana", imagen) | |
cv2.waitKey() |
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
<?php | |
class MyClass { | |
public $logger; | |
public function send($message) { | |
return $this->logger->info($message); | |
} | |
} | |
?> |
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
<?php | |
class MyClass { | |
private $logger; | |
public function setLogger(LoggerInterface $logger) { | |
$this->logger = $logger; | |
} | |
public function send($message) { | |
return $this->logger->info($message); | |
} |
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
<?php | |
class MyClass { | |
private $logger; | |
public function __construct(LoggerInterface $logger) { | |
$this->logger = $logger; | |
} | |
public function send($message) { | |
return $this->logger->info($message); | |
} |
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
import javax.microedition.midlet.MIDlet; | |
import javax.microedition.lcdui.CommandListener; | |
import javax.microedition.lcdui.Display; | |
import javax.microedition.lcdui.Command; | |
import javax.microedition.lcdui.Displayable; | |
import javax.microedition.lcdui.TextBox; | |
public class HolaMidlet extends MIDlet implements CommandListener { | |
private Display display; | |
private Command cmdExit; |
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
import javax.microedition.midlet.MIDlet; | |
public class HolaMidlet extends MIDlet 4 | |
{ | |
public HolaMidlet (){} | |
public void startApp(){} | |
public void pauseApp(){} | |
public void destroyApp(boolean unconditional){} | |
} |
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
//Terminals | |
var cuantos = ToTerm("cuantos"); | |
var cuantas = ToTerm("cuantas"); | |
var cual = ToTerm("cual"); | |
var que = ToTerm("que"); | |
var cuando = ToTerm("cuando"); | |
var tiene = ToTerm("tiene"); | |
/* más aquí */ | |
var number = new NumberLiteral("number"); | |
var number2 = new NumberLiteral("number2"); |
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
class Point { | |
constructor(x, y) { | |
this.x = x; | |
this.y = y; | |
} | |
toString() { | |
return '(' + this.x + ', ' + this.y + ')'; | |
} | |
} | |