A nice easy steps based learning for how to create an object in salesforce

what you must have in your pocket 
step no 1: you must have sandbox in your salesforce ;as you must sign up for sandbox developer edition 
go to your sandbox or developer organization
go to setup there go to create objects and now click for New Custom Object
enter label there 
click save
done hurrah ! you have created it 
now enter price for what you have inserted as label and if you want upto what decimal places you wanna to allocate place 2 or 3 etc.
however in the final you have created an object in your salesforce

steps and syntax for adding trigger in how to create an object in salesforce

let’s say we wanna to add trigger for tables:

Force.com platform database. Every trigger runs with a set of context variables that provide access to the records that caused
the trigger to fire. All triggers run in bulk; that is, they process several records at once.
1. From Setup, click Create > Objects and click the name of the object you just created, Book.
2. In the triggers section, click New.
3. In the trigger editor, delete the default template code and enter this trigger definition:
trigger HelloWorldTrigger on Book__c (before insert) {
Table__c[] tables = Trigger.new;
MyHelloWorld.applyDiscount(tables);}

steps and syntax for adding a class in salesforce.com

The Table custom object how to create an object in salesforce

In this step, you add an Apex class that contains a method for updating the book price. This method is called by the trigger
that you will be adding in the next step.
1. From Setup, click Develop > Apex Classes and click New.
2. In the class editor, enter this class definition:

We  can just use the name of the class followed by a dot (.) and the
name of the method. This method is called applyDiscount, and it is both public and static. Because it is a static method, you don’t need to
create an instance of the class to access the method.
This method takes one parameter, a list of Book records, which is assigned to the variable books.

public class MyHelloWorld {
public static void applyDiscount(Table__c[] tables) {
for (Table__c b :tables){
b.Price__c *= 0.7;
}
}
}

For more,Click here