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
{ | |
"name": "youname/project", | |
"autoload" : { | |
"psr-4": { | |
"Namespace\\" : "src/Namespace" | |
} | |
} | |
} |
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 ClassTask1{ | |
public static void main(String[] args){ | |
// Це одностроковий коментар | |
// System.out.println - це функція, яка виклакається для виводу тексту або значення якоїсь змінної в консоль |
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
<?php | |
class UserManager | |
{ | |
/** | |
*@var \PDO | |
*/ | |
private $pdo; | |
public function __construct(){ |
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
<!-- Це коментар, який не відображається на сторінці в браузері, | |
він потрібен лише для тих, хто має читати ваш код --> | |
<!-- Тег meta - непарний тег, поки що не буду пояснювати його, він досить важкий, і має декілька форм --> | |
<!-- В даному випадку я його застосував для того, щоб українські та російські букви відображались корректно--> | |
<meta charset="utf-8"> | |
<!-- h1 - це парний тег, який призначений для створення заголовку першого рівня --> | |
<h1> | |
<!--Всього існує 6 рівнів різних заголовків: h1, h2, h3, ..., h6 ) --> |
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
/** | |
* Created by FreeFly on 06.11.2015. | |
*/ | |
public class Arr { | |
public static void main(String[] args) { | |
//Створення цілочисельного масиву з 10 елементів | |
int[] arr = new int[10]; | |
//Елементи масиву номеруються починаючи з нуля, тобто arr[9] - останій елемент масиву з 10 елементів | |
//Запис в нульовий елемент масиву числа 17 |
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
public class Func1 { | |
public static void showArray (int[] a){ | |
for (int i = 0; i < a.length; i++) { | |
System.out.println(a[i]); | |
} | |
} | |
public static void main(String[] args) { | |
int[] arr = {3, 8, 213, 23, 34}; |
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
import java.util.Scanner; | |
class Human{ | |
int age; | |
String name; | |
public void sayAboutSelf(){ | |
System.out.println("My name is " + this.name + ". I am " + this.age + " years old."); | |
} | |
} |
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
#include "stdafx.h" | |
#include <iostream> | |
using namespace std; | |
int NOD(int a, int b) { | |
if (a == 0) { | |
return b; | |
} | |
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
Hello, dear user :) | |
<?php | |
$date = date("Y-m-d H:i:s"); | |
$userIp = $_SERVER['REMOTE_ADDR']; | |
$lastLineInFile = "[$date] $userIp\r\n"; | |
$file = fopen("file.txt", "a+"); | |
fwrite($file, $lastLineInFile); | |
fclose($file); |
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
<?php | |
//*************** | |
//тут багато коду | |
//*************** | |
page_footer(); | |
$date = date("Y-m-d H:i:s"); | |
$userIp = $_SERVER['REMOTE_ADDR']; | |
$lastLineInFile = "[$date] $userIp\r\n"; | |
$file = fopen("file.txt", "a+"); |
OlderNewer