9lessons:Timeline Design using CSS and Jquery

9lessons:Timeline Design using CSS and Jquery

Link to 9lessons Programming Blog

Timeline Design using CSS and Jquery

Posted: 30 Jun 2014 11:15 AM PDT

Timeline design is the current web trend that visualizes the data in an interesting way. Today I want to discuss about how to design a timeline in a simple way with JSON data feed , that using CSS pseudo elements such as :before and :after. Pseudo elements are used to apply special effects to selectors. This post is a combination of my previous post, please take a quick look at this demo and try demo script with your WAMP server.

Timeline Design CSS and Jquery

Read more »


Post a Comment

C Programming

C Programming


Convert any number to word

Posted: 29 Jun 2014 09:39 PM PDT

Q. Write a C program to convert any number to words, for example if 
user entered number = 45764
then output = Four Five Seven Six Four

Ans.

/*c program for convert number to word*/
#include<stdio.h>
int main()
{

 int num,c,digit,r=0;
 char *ch[1000];
 printf("Enter Number/Digit : ");
 scanf("%d", &num);
 while(num)
 {
  digit=num%10;
  num=num/10;
  switch(digit)
  {
    case 0: ch[r++]="Zero"; break;
    case 1: ch[r++]="One"break;
    case 2: ch[r++]="Two"break;
    case 3: ch[r++]="Three"break;
    case 4: ch[r++]="Four"break;
    case 5: ch[r++]="Five"break;
    case 6: ch[r++]="Six"break;
    case 7: ch[r++]="Seven"break;
    case 8: ch[r++]="Eight"break;
    case 9: ch[r++]="Nine"break;
  }
 }
 printf("Your Entered Number In Word : ");
 for(c=r; c>=0; c--)
    printf("%s", ch[c]);
 getch();
 return 0;
}


/************************************************************

The output of above program would be:
**************************************************************/

Output for Convert number to word C program
Figure: Screen shot for Convert number to word C program


Related program:

  1. Convert any number to grammatical words C program
  2. Comparison of million/billion/trillion VS lakh/crore/kharab


Post a Comment

9lessons:CSS3 Animation Effects with Keyframes

9lessons:CSS3 Animation Effects with Keyframes

Link to 9lessons Programming Blog

CSS3 Animation Effects with Keyframes

Posted: 17 Jun 2014 08:38 AM PDT

Using CSS3 keyframe property, you can create cool animation effects without using any JavaScript frameworks, CSS3 & HTML5 is helping to solve many web problems in a simple way. In this article I want to discuss how to implement CSS3 animations in a better way, use these and enrich your web projects. Take a quick look at these demos and try all these with modern browsers like Chrome, Firefox and Safari, sure you will love these effects.

CSS3 Animation Effects with Keyframes

Read more »

FileGator: A Look into The Powerful PHP File Management Tool.

Posted: 17 Jun 2014 08:37 AM PDT

Forget the times of 'There's an app for that', PHP scripts are now all the rage! Everyone wants to build their own little something special on the internet and mark their territory. With what we are witnessing on the internet front has been pretty moving and compelling enough to push us to try a few things ourselves. Thinking of file-sharing service for your friends, family, colleagues or business partners with all your rules? 'There's a script for that'!

Read more »


Post a Comment

C Programming

C Programming


Comparison Million Billion Trillion - Lakh Crore Kharab Series

Posted: 13 Jun 2014 09:00 AM PDT

In daily life we are many time confused about the equality of differ type number unit as million,billion,trillion v/s lakh,crore,kharab etc.
So today let's now knowing about How much million in Lakh and whether a billion is das lakh or ek Arab(i.e. simply Arab).


The answer of above question may be differ as a geographic location. In Europe continents(i.e all english countries) peoples representing the number as Million, Billion, Trillion whereas Asia continents peoples representing the number as Lakh, Crore, Kharab and so on.
Let's comparison of number representing system in tabular format:


S.No. Number's Range Hindi numeration in Roman scripts Numeration in English
1 11 Ikaai One
1 101 Dahaai Ten
2 102 Senkda Hundred
3 103 Hazar Thousand
4 104 Das Hazar Ten Thousand
5 105 Lakh Hundred Thousand
6 106 Das Lakh Million
7 107 Crore Ten Million
8 108 Das Crore Hundred Million
9 109 Arab Billion
10 1010 Das Arab Ten Billion
11 1011 Kharab Hundred Billion
12 1012 Das Kharab Trillion
13 1013 Neel Ten Trillion
14 1014 Dus Neel Hundred Trillion
15 1015 Padam Thousand Trillion
16 1016 Dus Padam Ten thousand Trillion
17 1017 Shankh Hundred Thousand Trillion
18 1018 Dus Shankh thousand thousand Trillion

Table: Comparison Million Billion Trillion v/s Lakh Crore Kharab Series


Related Programs:
  1. Convert any number to grammatical words C program
  2. Convert any number to simple words C program


Post a Comment

9lessons:Web PDF Viewer

9lessons:Web PDF Viewer

Link to 9lessons Programming Blog

Web PDF Viewer

Posted: 09 Jun 2014 01:36 PM PDT

Are you working for eLearning projects? then you should know about Mozilla has launched PDF.js a web PDF viewer plugin. This plugin helps you to display PDF files inside HTML code. I did customized PDF.js prebuild structure for easy usage. Take a quick look at this post and it will explain you how to configure and monetize your PDF content with HTML page.

Twitter OAuth Status Update using PHP.

Read more »


Post a Comment

C Programming

C Programming


Convert Any Digital Number Value In Words

Posted: 03 Jun 2014 10:39 PM PDT

Q. Write a C program that convert any digital number value in worlds as:

User entered value: 895484
then output in words as:
Eight Lakh Ninety Five Thousand Four Hundred Eighty Four

Ans.

/*c program that convert any digital number to words*/
#include<stdio.h>
#include<conio.h>
#include<math.h>

void checkNumber(int num);
void checkNumber1(int num);
void checkNumber2(int num);
void checkNumber3(int num);
void checkNumber4(int num);

void value1(int num);
void value2(int num);
void value3(int num1,int num2);

int main()
{

 int num;
 printf("Enter any Number : ");
 scanf("%d",&num);
 printf("Entered Number is : ");
 if(num<=100)
   checkNumber1(num);
 else if(num>100 && num<1000)
   checkNumber2(num);
 else if(num>=1000 && num<=100000)
   checkNumber3(num);
 else if(num>100000 && num<=10000000)
   checkNumber4(num);
 else
   checkNumber(num);
 getch();
 return 0;
}

void checkNumber(num)
{
  printf("Kindly enter the number between 0 to 10000000");     
}

void checkNumber1(num)
{
 int x,y,z;
 if(num>=0 && num<=10)
    value1(num);
 else if(num>10 && num<20)
 {
    x=num%10;
    value2(x);
 }
 else if(num>=20 && num<=100)
 {
    y=num/10;
    z=num%10;
    value3(y,z);
 }
}

void checkNumber2(int num)
{
 int x,y,z;
 y=num/100;
 value1(y);
 printf(" Hundred ");
 x=num%100;
 checkNumber1(x);
}

void checkNumber3(int num)
{
 int x,y,z;
 if(num==1000)
 {
   printf(" Thousand ");
   exit(0);
 }
 else if(num==100000)
 {
   printf("Lakh");
   exit(0);
 }
 else
 {
   x=num/1000;
   checkNumber1(x);
   printf(" Thousand ");
   z=num%1000;
   if(z<=99)
     checkNumber1(z);
   else
     checkNumber2(z);
 }
}

void checkNumber4(int num)
{
 int x,y;
 if(num==10000000)
 {
   printf("One Crore");
   exit(0);
 }
 x=num/100000;
 checkNumber1(x);
 printf(" Lakhs ");
 y=num%100000;
 if(y==0)
   exit(0);
 else if(y<=99)
   checkNumber1(y);
 else if(y>99 && y<=999)
   checkNumber2(y);
 else
   checkNumber3(y);
}

void value1(int num)
{
 switch(num)
 {
  case 0: printf("Zero"); break;
  case 1: printf("One"); break;
  case 2: printf("Two"); break;
  case 3: printf("Three"); break;
  case 4: printf("Four"); break;
  case 5: printf("Five"); break;
  case 6: printf("Six"); break;
  case 7: printf("Seven"); break;
  case 8: printf("Eight"); break;
  case 9: printf("Nine"); break;
  case 10: printf("Ten"); break;
  default: printf("");
 }
}

void value2(int num)
{
 switch(num)
 {
  case 1: printf("Eleven"); break;
  case 2: printf("Twelve"); break;
  case 3: printf("Thirteen"); break;
  case 4: printf("Fourteen"); break;
  case 5: printf("Fifteen"); break;
  case 6: printf("Sixteen"); break;
  case 7: printf("Seventeen"); break;
  case 8: printf("Eighteen"); break;
  case 9: printf("Nineteen"); break;
  default: printf("");
 }
}
void value3(int num1,int num2)
{
 switch(num1)
 {
  case 2: printf("Twenty "); break;
  case 3: printf("Thirty "); break;
  case 4: printf("Forty "); break;
  case 5: printf("Fifty "); break;
  case 6: printf("Sixty "); break;
  case 7: printf("Seventy "); break;
  case 8: printf("Eighty "); break;
  case 9: printf("Ninety "); break;
  case 10: printf("Hundred"); break;
  default: printf("");
 }
 value1(num2);

}

/*************************************************************
The output of above program would be:
**************************************************************/

Output of Convert Number to Word C Program
Figure-1: Screenshot for convert number to words C program

Output of Convert Number to Word C Program
Figure-2: Screenshot for convert number to words C program

Related program:

  1. Convert Number to word C program


Post a Comment

IPL Twenty20 Cricket

IPL Twenty20 Cricket


Chennai won by 7 wickets, Mumbai eliminated in IPL7

Posted: 03 Jun 2014 06:20 AM PDT

Toss :Chennai Super Kings won the toss and elected to field

Result : Chennai Super Kings won by 7 wickets

Match Summary:

Mumbai Indians : 173/8 in 20 overs

Lendl Simmons - 67
Michael Hussey - 39

Mohit Sharma - 3/42


Chennai Super Kings : 176/3 in 18.4 overs

Suresh Raina - 54*
David Hussey - 40*

Man of the Match : Suresh Raina

KKR Entered Final in IPL7

Posted: 03 Jun 2014 06:05 AM PDT

Toss : Kings XI Punjab won the toss and elected to field

Result : Kolkata Knight Riders won by 28 runs

Match Summary:

Kolkata Knight Riders : 163/8 in 20 overs

Robin Uthappa - 42
Manish Pandey - 21

Karanveer Singh - 3/40


Kings XI Punjab : 135/8 in 20 overs

Wriddhiman Saha - 35(31)
George Bailey - 26(17)

Umesh Yadav - 3/13

Man of the Match : Umesh Yadav


Post a Comment

C Tutor...

C Tutor...


C Program to convert infix to postfix expression

Posted: 02 Jun 2014 09:49 AM PDT

C Program to convert infix to postfix expression 





#include
#include
char infix[100],post[100];
int top=0,stack[10];
void push(int);
char pop();
void postfix();
main()
{
char ch;
clrscr();
printf("\n Infix Expression ");
gets(infix);
postfix();
getch();
}


void postfix()
{
int i=0,j=0;
for(i=0;infix[i]!='\0';i++)
{
switch(infix[i])
{
case '+': while(stack[top]>=1)
post[j++]=pop();
push(1);
break;
case '-': while(stack[top]>=1)
post[j++]=pop();
push(2);
break;
case '*': while(stack[top]>=3)
post[j++]=pop();
push(3);
break;
case '/': while(stack[top]>=3)
post[j++]=pop();
push(4);
break;
case '^': while(stack[top]>=4)
post[j++]=pop();
push(5);
break;
case '(': push(0);
break;
top--;
break;
default: post[j++]=infix[i];
}
while(top>0)
post[j++]=pop();
printf("\n The postfix expression is %s\n",post);
}


void push(int element )
{
top++;
stack[top]=element;
}
char pop()
{
int ele;
char ex;
ele=stack[top];
top--;
switch(ele)
{
case 1: ex='+';
break
case 2: ex='-';
break;
case 3: ex='*';
break;
case 4: ex='/';
break;
case 5= ex='^';
break;
}
return ex;
}




C Program to check whether a given matrix is symmetric or not

Posted: 02 Jun 2014 09:48 AM PDT

C Program to check whether a given matrix is symmetric or not 


A matrix is symmetric if its transpose is same as the matrix itself check the martix by using C Logic.





#include
#include

//write matrix
void write_mat(int a[][10],int n)
{
int i,j;
{
for(i=0;i<n;i++)
for(j=0;j<n;j++)
printf("%10d",a[i][j]);
printf("\n");
}
}

//read matrix
void read_mat(int a[][10],int n)
{
int i,j;
printf("Enter %d X %d matrix below:\n",n,n);
for(i=0;i<n;i++)
for(j=0;j<n;j++)
scanf("%d",&a[i][j]);
}

//main function
void main()
{
int a[10][10],i,j,n;

//accept matrix
printf("Enter size of square matrix");
scanf("%d",&n);
read_mat(a,n);

//check if the matrix is symmetric or not
for(i=0;i<n;i++)
for(j=i+1;j<n;j++)
if(a[i][j]!=a[j][i])
{
printf("Not symmetric");
return;
}
printf("Symmetric");
getch();
}




Java Program to find nth term in a TRIBONACCI series

Posted: 02 Jun 2014 09:45 AM PDT

Java Program to find nth term in a TRIBONACCI series






import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Tribonacci {

/**
* @param args
*/
public static void main(String[] args) throws IOException {
// TODO Auto-generated method stub
BufferedReader reader = new BufferedReader(new InputStreamReader(
System.in));
System.out.println(" Enter the number ");
int num = Integer.parseInt(reader.readLine());
int first = 0, second = 1, third = 1, nthTerm = 0;
int num1 = num;
if (num == 1)
nthTerm = 0;

if (num == 2 || num == 3)
nthTerm = 1;

while (num > 3) {
nthTerm = first + second + third;
// System.out.print(d +"\t");
num--;
first = second;
second = third;
third = nthTerm;
}
System.out.print(num1 + "th term of the Tribonacci is " + nthTerm);
}
}




C Program to count the number of ones in a 32 bit number.

Posted: 02 Jun 2014 09:44 AM PDT

C Program to count the number of ones in a 32 bit number. 



#include

int bitcount(unsigned int n)
{
int count=0;
while(n)
{
count+=n& 0x1u;
n>>=1;
}
return count;
}

void main()
{
unsigned int g; int n;
printf(" \n Enter the number : \n");
scanf("%u",&g);
n=bitcount(g);
printf("It has %d ones",n);
}








Post a Comment