Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- require "inc.sessioonid.php";
- ?>
- <!DOCTYPE html>
- <html lang="et">
- <head>
- <title>Ruutvõrrandi lahendamise statistika</title>
- <meta charset="utf-8">
- <style>
- input{
- width: 50px;
- }
- .nupp{
- width: auto;
- }
- body{
- background-color: #DCDCDC;
- font-family: "Comic Sans Ms";
- color: #000000;
- }
- </style>
- </head>
- <body>
- <?php
- //NAVIGATSIOONI JURA
- include 'inc.navigatsioon.php';
- ?>
- <?php
- $mida = array();
- $jura = file("failid/ruutvorrand.txt");
- foreach ($jura as $j) {
- $muut = substr( $j, 0, strpos( $j, ' ' ) );
- $mida[] = $muut;
- }
- $hihi = array_count_values($mida);
- arsort($hihi);
- $pop = array_keys($hihi);
- echo "<br>Kõige tihedamini esinev ruutliikme kordaja on ".$pop[0];
- ?>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement