Tuesday 14th October 2008
 
 
 
 
 
 


 
 

[C] Implement of strcmp

November 16, 2006 Author: Chris T Posted in: Code Tutorials
 

A simple program to understand how to work with strings.

#include <stdio.h>
#include <stdlib.h>
 
int main(void)
{
char name[10] =  {'H','E','L','L','O'}  ;
char name2[10] = {'G','O','O','D','B','Y','E'} ; 
char temp[10] ;     
int i;
 
printf("Name 1 is %s\n",name);
printf("Name 2 is %s\n",name2);
printf("\n");
for(i=0; i<10; i++) {
 
       temp[i]= name[i];
       name[i] = name2[i]; 
       name2[i] = temp[i];
}
 
printf("After The string copy function\n");
printf("\n");   
 
printf("Name 1 is %s\n",name);
printf("Name 2 is %s\n",name2);
 
    system("PAUSE");
    return 0;   
  }
 
Views: 2,158
 
 

 
 

[C] Square, Sum, Product

November 16, 2006 Author: Chris T Posted in: Code Tutorials
 

A very simple program written in c which calculates the square, the sum and the product of numbers from 1 to 10. A good functions introduction in c.

#include <stdio.h>
 
int main(void)
{
int x,y=0,g=1;
 
   for (x = 1;x <= 10;x++){ 
      printf("The %1d^2 is=%d \n",x,squ(x));
      y = sum(x,y);
      g = tot(x,g);
 
   }
    printf("The sum of numbers  is %d\n",y);
    printf("The product of numbers  is %d\n",g);
 
system("PAUSE");
  return 0;
}
 
tot(x,g)
int x,g;
{
int total;
 
   total = x * g;
   return(total); 
}
sum(x,y) 
int x,y;
{
int sum;
 
   sum = y + x;
   return(sum); 
}
 
squ(in) 
int in;
{
int square;
 
   square = in * in;
   return(square);
}
 
 
Views: 2,226
 
 

 
 

[C] Magic Number

November 16, 2006 Author: Chris T Posted in: Code Tutorials
 

A simple program in c which the program choose one random number from 1-500 and the user has to guess that number. The program notifies user if his guess is too low or too hight and counts all the user tries.

#include <stdio.h>
#include <stdlib.h>
#include <time.h>
 
int main(void) {     
    int magic, guess, counter;
    srand(time(NULL));
 
    magic=(rand()%500)+1;
    counter=0;
 
    do { printf ("Make Your Guess: ");
 
   scanf ( "%d" , &guess);   
         counter++;                       
 
         if ( guess==magic ) {
              printf ( "You have found it after %d trial(s) , " , counter);
              printf ( "%d is the number ! \n" , magic );
              }
         else {
               printf ( "Wrong number , You are ");
               if ( guess > magic)  printf ("Too high... ");
               else  printf ("Too low... ");
               printf ( "You have made %d trial(s) \n" , counter);
               }         
}while (guess!=magic);                         
 
system("PAUSE");
return 0;   
}
 
Views: 2,449
 
 

 
 

[c++] Working with classes

November 16, 2006 Author: Chris T Posted in: Code Tutorials
 

This is a good tutorial working with classes in c++. Our program starts and asks the user to enter the coordinates of two points. The program returns the middle point and the distance between the two points.

#include <iostream>
#include <math.h>
using namespace std;
 
class Point
{
      private:
              double x,y;
      public:
             Point() { x=y=0;}
             Point(double a) {x=y=a;}
             Point(double a, double b) {x=a; y=b;}
             void Point::display() { cout <<"("<<x<<","<<y<<")"<<endl; }
             double Point::get_y() {return y;}
             double Point::get_x() {return x;}
};       
 
class Segment
{
      private:
              Point p1,p2,mid;
              double xm,ym,len, tmp1, tmp2;
      public:
             Segment(Point a) { Point p; p1=p; p2=a;}   
             Segment(Point a, Point b) { p1=a; p2=b;}
             void Segment::display()
             {    cout <<"The first point is: ";
                  p1.display();
                  cout <<"The second point is: ";
                  p2.display();
 
             }
             void Segment::middle()
             {
                  xm = (p2.get_x() + p1.get_x())/2;
                  ym = (p2.get_y() + p1.get_y())/2;
                  Point mid(xm,ym);
                  cout <<"To middle point is: ";
                  mid.display();
             }
             void Segment::length()
             {   
                tmp1 = (p2.get_x()-p1.get_x()) * (p2.get_x()-p1.get_x());
                //DEBUG cout <<tmp1<<endl;
                tmp2 = (p2.get_y()-p1.get_y()) * (p2.get_y()-p1.get_y());
                //DEBUG cout <<tmp2<<endl;
                len = sqrt(tmp1 + tmp2);
                cout <<"The distance between these two points is:"<<len<<endl;
             }     
};
 
int main ()
{
    double x1, y1, x2, y2;
 
    //Point p1;
    //p1.display();
    //Point p2(3);
    //p2.display();
    //Point p3(-1,8);
    //p3.display();
    //Point p4(3,6);
    //p4.display();
 
    cout <<"Enter x1:";
    cin >> x1;
    cout <<"Enter y1:";
    cin >> y1;
 
    cout <<"Enter x2:";
    cin >> x2;
    cout <<"Enter y2:";
    cin >> y2;
 
    Point p5(x1,y1);
    Point p6(x2,y2);;
 
    Segment s1(p5,p6);
    s1.display();
    s1.middle();
    s1.length();
 
    system("PAUSE");
    return 0;
}
 
 
Views: 2,595
 
 

 
 

T3 Exodus v2.0

November 15, 2006 Author: Chris T Posted in: Seditio Skins
 

Installation

~~~~~~~~~~~~

Extract the .rar file.

Upload the folder t3-exodusv2 to your /skins/ folder.

Set the skin T3-Exodus V2.0 in your profile, or as default in /datas/config.php

Author Notes

~~~~~~~~~~~~

In the package you can also find:

- The original .psd files

- The fonts that used for various graphics.

- There are also some misc images that you can use with future plugins.

User Notes

~~~~~~~~~~

You are not allowed to remove the tag Skin Made By T3-Design.com

If you need to remove it contact me to find a solution.

If you like it don’t forget to leave your comment and rating.

Download T3 Exodus v2

 
Views: 4,922
 
 

 
 

Smilies Pack 2

November 14, 2006 Author: Chris T Posted in: Graphics
 

This is the second smiles pack. Most of them are animated so to see them in real action you must download them. 187 Smilies in the package.

Download Smilies Pack 2

 
Views: 5,224
 
 

 
 

Women avatars

November 14, 2006 Author: Chris T Posted in: Graphics
 

A nice pack of 136 90×90 sexy women.


Downloads Women Avatars

 
Views: 3,945
 
 

 
 

Tv avatars

November 14, 2006 Author: Chris T Posted in: Graphics
 

A nice pack of 38 90×90 tv series avatars.

Download TV Avatars

 
Views: 2,938
 
 

 
 

Nature avatars

November 14, 2006 Author: Chris T Posted in: Graphics
 

A nice pack of 85 90×90 nature avatars.

Download Nature Avatars

 
Views: 2,725 Tags: ,
 
 

 
 

Movies Avatars

November 14, 2006 Author: Chris T Posted in: Graphics
 

A nice pack of 38 90×90 movies avatars.

Download Movies Avatars

 
Views: 2,970 Tags: ,
 
 

Page 1 of 212»