Advertisement
MusicFreak

DA BOG DA UMRO!

Feb 19th, 2013
212
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 1.99 KB | None | 0 0
  1. <html>
  2. <head>
  3. <script type="text/javascript">
  4. function prikazi()
  5. { var broj=prompt("Unesite broj", "unesite broj");
  6. if (broj!=null && broj!="")
  7. {document.write((broj)*(broj)*(broj))}
  8. }
  9. </script>
  10. </head>
  11. <body>
  12. <input type="button" onclick="prikazi()" value="Click you fool!"/>
  13. </body>
  14. </head>
  15. </html>
  16.  
  17. ============================================================================================================================
  18.  
  19. <html>
  20. <head>
  21. <script type="text/javascript">
  22. function bla(a, b, c)
  23. {
  24.     if (a<=0 || b<=0 || c<=0) return false;
  25.     else
  26.     {
  27.         if ( ( (a>=b && a<=c) || (a<=b && a>=c) ) && (a*a*a == a*b*c) ) return true;
  28.         if ( ( (b>=a && b<=c) || (b<=a && b>=c) ) && (b*b*b == a*b*c) ) return true;
  29.         if ( ( (c>=a && c<=b) || (c<=a && c>=b) ) && (c*c*c == a*b*c) ) return true;
  30.         return false;      
  31.     }
  32.    
  33. }
  34.  
  35. </script>
  36. </head>
  37. <body>
  38. <script type="text/javascript">
  39. document.write(bla(2,10,50));
  40. </script>
  41. </body>
  42. </html>
  43.  
  44. ==========================================================================================================================================================
  45.  
  46. #include <iostream>
  47. #include <fstream>
  48. using namespace std;
  49. int main ()
  50. {
  51.     ifstream test;
  52.     string s;
  53.     test.open("ulaz.txt");
  54.     getline(test,s);
  55.     test>>s;
  56.     cout<<s<<endl;
  57.    test.close();
  58.    system ("Pause");
  59.    return 0;
  60. }
  61.  
  62. =====================================================================================================================
  63.  
  64. #include <iostream>
  65. #include <fstream>
  66. #include <cstdlib>
  67. #include <string>
  68.  
  69. using namespace std;
  70.  
  71. int main()
  72. {
  73.     fstream ulaz, izlaz;
  74.     ulaz.open("ulaz1.txt");
  75.     izlaz.open("izlaz1.txt");
  76.     int i=0, a;
  77.     while (ulaz.good())
  78.     {
  79.           ulaz>>a;
  80.           izlaz<<a;
  81.          i++;
  82.          if (i == 4)
  83.        {
  84.            izlaz << "\n";
  85.            i = 0;
  86.        }
  87.          }
  88.          ulaz.close();
  89.          izlaz.close();
  90.          system("Pause");
  91.          return 0;
  92.          }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement