Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View primats's full-sized avatar

primat.org primats

View GitHub Profile
@primats
primats / fibon.html
Last active April 9, 2016 08:15
Числа Фибоначчи
<!DOCTYPE HTML>
<html>
<title>Числа Фибоначчи</title>
<head>
<meta charset="utf-8">
</head>
<body>
<script type="text/javascript">
function fib(n){
if (n==1||n==2) return 1;
<style>
#pic {
width: calc(100% - 4px);
height: 115px;
position: relative;
line-height:17px;
text-align:center;
border:2px #cecece solid;
}
<style>
.bg { background:
url(http://primat.org/picture/raznoe/png-background.png);
padding: 00px;
display: inline-block;
float: left;
}
div#buttons button {margin-right:5px;margin-bottom:10px;}
div#buttons input {margin-left:-5px;margin-right:5px;
<!DOCTYPE html>
<html>
<head>
<title>math.js | plot</title>
<script src="http://cdnjs.cloudflare.com/ajax/libs/mathjs/2.5.0/math.min.js"></script>
<!-- load http://maurizzzio.github.io/function-plot/ -->
<script src="http://cdnjs.cloudflare.com/ajax/libs/d3/3.5.5/d3.min.js"></script>
<script src="https://wzrd.in/standalone/function-plot@1.14.0"></script>
<!DOCTYPE html>
<html lang="ru">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta charset="utf-8">
<title>Красивый список</title>
<link href='http://fonts.googleapis.com/css?family=Exo+2:400,100&subset=latin,cyrillic' rel='stylesheet' type='text/css'>
</head>
<body>
<table>
<script language="JavaScript">
document.write("<tr><td bgcolor='#918E8A'>X</td>");
for (i = 1; i <=10; i++) document.write("<td bgcolor='#918E8A'>"+i+" </td>");
document.write("</tr>");
for (i = 1; i <=10; i++)
{
document.write("<tr><td bgcolor='#918E8A'>" + i + " </td>");
for (j = 1; j <= 10; j++)
{
@primats
primats / буквица для текста.css
Last active December 21, 2015 09:31
Буквица для абзаца
# стиль для оформления первой буквы абзаца
p:first-letter {
float: left;
margin-right: 10px;
font: 2.2em/1 Georgia;
text-shadow: 1px 1px 3px silver;
color: crimson;
}
<style>
table,tr,td {font-size:11px !important;}
</style>
<div style="width:100%">
<table border=0 cellspacing=5 cellpadding=0 width=100% valign=top>
<tr><td colspan=4>
</td></tr>
@primats
primats / chessboard.html
Last active November 1, 2018 18:44
Шахматная доска на канве
<html>
<head>
<title>Шахматная доска на канве</title>
</head>
<body>
<canvas id='example'>Обновите браузер</canvas>
<script>
var example = document.getElementById("example");
var ctx = example.getContext('2d');
example.width = 300;