Κυριακή 22 Μαΐου 2016

Kill the king of the iron throne

Kill the king, Game of Thrones edition.
I do not own the rights for the videos nor the music used for this video clip.
I made a video editing from HBO's and G.R.R. Martin's Game of thrones exceptional TV production
using the Rainbow's (great DIO's era) Kill the king song from the Long Live Rock'n'Rosll LP
for recreational and educational reasons.

ATTENTION! Spoiler Alert

From a fan to other fans, thanks for watching.
Enjoy.

Polykarpos


Πέμπτη 12 Μαΐου 2016

COBOL programmers are COOL

COBOL was designed in 1959, by CODASYL and was partly based on previous programming language design work by Grace Hopper, commonly referred to as "the (grand)mother of COBOL".[8][9][10] It was created as part of a US Department of Defense effort to create a portable programming language for data processing. Intended as a stopgap, the Department of Defense promptly forced computer manufacturers to provide it, resulting in its widespread adoption.[11] It was standardized in 1968 and has since been revised four times. Expansions include support for structured and object-oriented programming. The current standard is ISO/IEC 1989:2014.[12]
source: wikipedia





another one bytes the dust







Τετάρτη 11 Μαΐου 2016

Lucky six (in c not plusplus)


The origin of C is closely tied to the development of the Unix operating system, originally implemented in assembly language on a PDP-7 by Ritchie and Thompson, incorporating several ideas from colleagues. Eventually, they decided to port the operating system to a PDP-11. The original PDP-11 version of Unix was developed in assembly language. The developers were considering rewriting the system using the B language, Thompson's simplified version of BCPL.[9] However B's inability to take advantage of some of the PDP-11's features, notably byte addressability, led to C.
The development of C started in 1972 on the PDP-11 Unix system[10] and first appeared in Version 2 Unix.[11]
From wikipedia

Ένα προγραμματάκι, randomizer, που παράγει 6 τυχαίους αριθμούς (αν θέλετε για να παίξετε Lotto) και κατόπιν ταξινομεί τον πίνακα που τους αποθηκεύει με ένα nested For Loop, quite elegant solution I'd say
The source code
#include <stdio.h>
#include <conio.h>
int newRandNumb();
int main(void){
int i=0;
srand(time(NULL));
i=0;
int y=0;
int chosenNums[5];
int generatedNum=0;

while (i<6){
generatedNum=newRandNumb();
if (generatedNum==0){
while(generatedNum==0){
generatedNum=newRandNumb();
}
}
if(i>0){
y=0;
do{
if (generatedNum == chosenNums[y]){
y=0;
generatedNum=newRandNumb();
while(generatedNum == chosenNums[y]){
generatedNum=newRandNumb();
}
}
y++;
} while (y <i);
}
chosenNums[i]=generatedNum;
i++;
}
printf("The lucky six are: ");
for (i=0;i<6;i++){
printf("%d,",chosenNums[i]) ;
}


printf("\n\nArranging the numbers in ascending order \n\n");

int orderArray[5];

i=0;
y=0;
int x=0;
int r=0;

for (i=0;i<6;i++){
for (y=0;y<6;y++){
if (chosenNums[i] < chosenNums[y] && y < i){
r=chosenNums[i];
chosenNums[i]=chosenNums[y];
chosenNums[y]=r;
} /*else if (chosenNums[i] > chosenNums[y] && y > i) {
r=chosenNums[y];
chosenNums[y]=chosenNums[i];
chosenNums[i]=r;
}*/
}
}
for (i=0;i<6;i++){
printf(" \nthe order is %d",chosenNums[i]);
}
getch();
return 0;
}
int newRandNumb(){
return (rand()%47);
}