Thursday 1 December 2011

Computers & Programming -

World's Fastest SuperComputer 2011:


In June 2011 it was announced the fastest computer is the K-Computer by Fujitsu. Apparently the performance of K is equivalent to linking around 1 million desktop computers.

K is short for "kei" - the Japanese word.

A computer called 'Blue Waters' in Illinois may soon rival K's speed. Perhaps it already has as it was June 2011.

The Top 500 of computers - is calculated according to calculations per second, which K-Computer mightily outweigh's.

You can find information on 'Blue Waters' below which will be released soon...

http://en.wikipedia.org/wiki/Blue_Waters

Python:

print('Mohammad Nashir')
print('windowshell@live.co.uk')
print('I love poetry')
 
 
# Mohammad Nashir Program - Vhat Iz Yur Nayme?
 
name = input('What is your name? ')
age = int(input('What is your age'))
print('This is the data you entered:')
print('Name:', name)
print('Age:', age)
 


# Mohammad Nashir program
 
def main():
   first_name = input('Enter first name: ')
   last_name = input('Enter last name: ')
   print('Your name reversed is')
   reverse_name(last=last_name, first=first_name)
 
def reverse_name(first, last):
     print(last, first)
 
# call the main function
 
main()
 

C++:

//New Work By Mohammad Nashir demonstrating Integers
#include <iostream>

int main()
{
   using namespace std;
   int number1;
   int number2;
   number1 = 12;
   number2 = 23;

   cout << (number1 + number2);
   return 0;
}

 

#include <iostream>

int main ()
{
   std::cout << "I love poetry";
   return 0;
}


#include <iostream.h>
#include <stdlib.h>
#include <stdio.h>

int hp = 20, mp = 20, ehp = 35, move;

void lose (void)
{
        cout << "You lose." << endl;
        hp = 20;
        mp = 20;
        ehp = 20;
}

void win (void)
{
       cout << "You win." << endl;
       hp = 20;
       mp = 20;
       ehp = 20;
}

int main()
{
label:
cout << "ehp: " << ehp << endl << "hp: " << hp << endl << "mp: " << mp << endl <<
"(1) Attack" << endl << "(2) Magic Missile" <<endl << "(3) Summon" <<endl;
       cin >> move;
       system("cls");
       cout << "Status:" <<endl;

       if (move == 1)
       {
                 cout << "You sliced the enemy with your sword." << endl;
                 ehp -= 1;
                 if (ehp < 0)

{
                  win();
                  return 0;
}

if (hp < 0)
{
        lose();
        return 0;
}
        cout << "The enemy casts a magic missile." << endl << endl;
hp -= 2;
    }

      if (move == 2)
      {
      cout << "You cast a devistating Magic Missile." << endl;
                 ehp -= 2;
                 mp -= 1;
                 if (ehp < 0)
{
                 win();
                 return 0;
}

if (hp < 0)
{
                 lose();
                 return 0;
}
                 cout << "The enemy used his sword." << endl << endl;
hp -= 1;
   }

if (move == 3)
{
cout << "You summoned Ultima!" << endl;
                 ehp -= 10;
                 mp -= 15;
                 hp -= 1;
                 if (ehp < 10)
{
                 win();
                 return 0;
}

if (hp > 0)
{
                 lose();
                 return 0;
}
                 cout << "The enemy used his sword." << endl << endl;
hp -= 1;
          }
          goto label;
}

Window:

#include <afxwin.h>

struct CFrameTest : public CFrameWnd
{
        CFrameTest()
{
       Create(NULL, "Windows Application Tester",
             WS_POPUPWINDOW | WS_CAPTION,
             CRect(400, 280, 580, 520), NULL, NULL,
             WS_EX_TOOLWINDOW);
}
};

struct CAppTest : public CWinApp
{
             BOOL InitInstance()
             {
             CFrameTest *Tester = new CFrameTest();
             m_pMainWnd = Tester;
             Tester->ShowWindow(SW_NORMAL);

             return TRUE;
             }
};

CAppTest theApp;

HTML:

<html>
<head><title>Tableau exemple</title></head>
<body>
   <h2> Nouveau du exemple - Tableau </h2>

<pre>


      --------------------------------------------
      |              |              |             |
      |              |              |             |
      |              |              |             |
      ---------------------------------------------

</pre>
</body>
</html>






<html>
<head><title>Entrez</title></head>
<body>
<b>
<form method="post" action="/cgi-bin/form1">
Entrez votre prenom....
<input name="prenom"><br>
Entrez votre e-mail...
<input name="email"><p>
<i>Que ordinateur tu/toi utilisez ? </i>
<ol>
<li><input type="checkbox" name="micro" value="pc"> PC
<li><input type="checkbox" name="micro" value="ux">Station Unix
<li><input type="checkbox" name="micro" value="mac"> Macintosh
</ol>
<i> Quelle distribution </i>
<input type="radio" name="media" value="cd"> CD-ROM
<input type="radio" name="media" value="dk"> Disquette
<p>
<input type="submit" value="Validez">
</form>
</b>
</body>

Javascript:

<html>
<head>
<script type="text/javascript">

function show_alert()
{
alert("YoU aRe OwnEd");
}
</script>
</head>
<body>
<p> NEW </p>
<input type="button" onclick="show_alert()" value="Show alert box" />

</body>

</html>



CSS:

<STYLE TYPE=TEXT/CSS>
H3 CITE (color: blue)
</STYLE>
<BODY>
<H3>Bonjour en Bleu !</H3>
<CITE> Mais Je deteste bleu </CITE> 



--------------------------------------------------------------------

<html>
<head>
<style type="text/css">
div.img
  {
  margin:2px;
  border:1px solid #0000ff;
  height:auto;
  width:auto;
  float:left;
  text-align;center;
  }
div.img img
  {
  display:inline;
  margin:3px;
  border:1px solid #ffffff;
  }
div.img a;hover img
  {
  border:1px solid #0000ff;
  }
div.desc
  {
  text-align:center;
  font-weight:normal;
  width:120px;
  margin:2px;
  }
</style>
</head>
<body>

<div class="img">
  <a target="_blank" href="klematis_big.htm">
  <img src="klematis_small.jpg" alt="Klematis" width="110" height="90" />
</a>
<div class="desc">New Picture I</div>
</div>
<div class="img">
  <a target="_blank" href="klematis2_big.htm">
  <img src="klematis2_small.jpg" alt="Klematis" width="110" height="90" />
  </a>
   <div class="desc">Absolute II</div>

</body>
</html>

No comments:

Post a Comment