This file contains 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
UPDATE movie | |
SET name='Men in Black' | |
WHERE id='5' | |
UPDATE movie | |
SET name='Deadpool',poster='https://upload.wikimedia.org/wikipedia/en/thumb/2/23/Deadpool_%282016_poster%29.png/220px-Deadpool_%282016_poster%29.png' | |
WHERE id='8' | |
UPDATE movie | |
SET comment='' |
This file contains 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
// Une requête récupère l'ensemble des films | |
SELECT * FROM `movie`; | |
// Une requête récupère les noms des films | |
SELECT name FROM `movie`; | |
// Une requête récupère l'ID et le poster | |
SELECT `id`,`poster` FROM `movie`; | |
// Une requête récupère le poster et le commentaire avec un alias sur la colonne "commentaire". |
This file contains 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8" /> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | |
<title>Counter Redux</title> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
This file contains 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
/[A]+[\.]/g "A." deuxième prénom => "A" + ".(échappé)" | |
/[\d]{2}\/[\d]{2}\/[\d]{4}/g date 31-03-1999 | |
/\s[\d]{1}\/[\d]{2}/g note => espace + 1 chiffre + "/" + 2 chiffres | |
/\w{14}/g mot de +de 14 caractères (c'est quoi la blague ???!) | |
/https?:\/\/[\w\.-]+\.[a-zA-Z]{2,4}(\/\S*)?\b/g lien http |
This file contains 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 cowsay = require("cowsay"); | |
console.log(cowsay.say({ | |
text : "hello boy", | |
e : "oO", | |
T : "U " | |
})); |
This file contains 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 CandyCount { | |
public static void main(String[] args) { | |
double money = 12.4; | |
double price = 1.2; | |
int candies = 0; | |
if (money > 0 && price > 0) { | |
while ((money - price) >= 0) { | |
candies++; | |
money-=price; |
This file contains 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
process.stdin.resume() | |
process.stdin.setEncoding('utf8') | |
console.log('How old are you ? ') | |
let year = 2018 | |
process.stdin.on('data', (age) => { | |
if (age < 99 && age > 0){ | |
console.log(("You was born in " ) + (year - age)) | |
} else { | |
console.log ("Error") |
This file contains 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
function hello(name: string) { | |
console.log("Hello " + name); | |
} | |
var firstName: string = "bob"; | |
hello(firstName); | |
hello(firstName + " marley"); | |
function concat(a: string, b: string) { |
This file contains 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 Senpai { | |
public static void main(String[] args) { | |
System.out.println("Notice me Senpai"); | |
} | |
} |
This file contains 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
<!DOCTYPE html> | |
<html lang="fr"> | |
<head> | |
<meta charset="utf=8" /> | |
<title>patates</title> | |
</head> | |
<body> | |
<script> | |
let answer = prompt('Hey mon ami ! Tu aimes ça les patates ?', '1 pour OUI / 2 pour NON'); |