Skip to content

Instantly share code, notes, and snippets.

@kuronana
kuronana / sf01
Last active October 29, 2018 09:57
sfQuest01
1 - Quelle est la société qui développe Symfony ?
- SensioLabs.
2 - Cite les autres produits développés par cette société ?
- Blackfire.IO.
- Twig.
@kuronana
kuronana / html file
Created October 22, 2018 12:30
quest js 01
<<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Hello Wilder</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body>
<script src="hello-wilder.js"></script>
-- MySQL dump 10.13 Distrib 5.7.23, for Linux (x86_64)
--
-- Host: localhost Database: sqlQuest03
-- ------------------------------------------------------
-- Server version 5.7.23-0ubuntu0.18.04.1
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
<?php
class personnages{
private $firstname;
private $name;
private $address;
private $birthYear;
public function __construct($firstname, $name, $address, $birthYear){
$this->firstname = $firstname;
$this->name = $name;
-- MySQL dump 10.13 Distrib 5.7.23, for Linux (x86_64)
--
-- Host: localhost Database: jess_v_wcs_stras
-- ------------------------------------------------------
-- Server version 5.7.23-0ubuntu0.18.04.1
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
<?php
function &writeSecretSentence(string $PARAMETRE_1, string $PARAMETRE_2)
{
$phraseMystere = $PARAMETRE_1.' s\'incline face à '.$PARAMETRE_2;
return $phraseMystere;
}
$mdp =& writeSecretSentence('La chevre', 'l\'hentai kamon');
echo $mdp;
?>
<?php
$weapons = ['fists', 'whip', 'gun'];
$oppenentWeapon = $weapons[rand(0,2)];
$indyWeapon = '???';
switch ($oppenentWeapon) {
case 'fists':
$indyWeapon = $weapons[2];
break;
case 'whip':
<?php
$tab1 = [
'Indiana Jones and the Kingdom of the Crystal Skull' => ['Harrison Ford', 'Cate Blanchett', 'Karen Allen' ],
'Indiana Jones and the Last Crusade' => ['Harrison Ford', 'Sean Connery', 'Denholm Elliott' ],
'Indiana Jones and the Temple of Doom' => [' Harrison Ford', 'Kate Capshaw', 'Jonathan Ke Quan' ]
];
foreach ($tab1 as $film => $acteur) {
echo 'Dans le film '.$film.', les principaux acteurs sont : '.$acteur[0].', '.$acteur[1].', '.$acteur[2].'.<br/>';
}
@kuronana
kuronana / php quete 2
Last active September 11, 2018 16:22
<?php
$msg = 'aopi?sgnirts@#?sedhtg+p9l!';
$nbTotal = mb_strlen($msg);
$chCles = $nbTotal / 2;
$rest = substr($msg, 5, $chCles);
$modif = str_replace('@#?', ' ', $rest);
/*
message 1 : aopi?sgnirts@#?sedhtg+p9l!
message 2 : q8e?wsellecif@#?sel@#?setuotpazdsy0*b9+mw@x1vj
<?php
$titleOfMovie = "Indiana Jones and the Last Crusade";
$score = 8.3;
$releaseDate = "1989";
$release = true;
echo "$titleOfMovie";
echo "<br/>";
echo "$score";
echo "<br/>";
echo "$releaseDate";