Language

‘Big Data’ impacts how we work, elect our presidents, and play tennis. It also affects the way we’re watched.’ They work a few hundred yards from one of the Library of Congress’s most prized possessions: a vellum copy of the Bible printed in 1455 by Johann Gutenberg, inventor of movable type. But almost six centuries later,... Read more »

August 18, 2013 at IST / Language.

How to use time object in java. public class Time1Test { public static void main(String args[]) { Time1 time=new Time1(); System.out.print("The initial universal time is : "); System.out.println(time.toUniversalString()); System.out.print("The initial standard time is : "); System.out.println(time.toString()); System.out.println(); time.setTime(13,27,6); System.out.print("Universal time after setTime is : "); System.out.println(time.toUniversalString()); System.out.print("Standard time after setTime is : "); System.out.println(time.toString()); System.out.println();... Read more »

October 4, 2012 at IST / Language.

Write a program to find which number is maximum. import java.util.Scanner; public class MaximumFinder { public void determineMax() { Scanner input=new Scanner(System.in); double a,b,c,maximum; System.out.print("Enter 3 numbers : "); a=input.nextDouble(); b=input.nextDouble(); c=input.nextDouble(); maximum=max(a,b,c); System.out.println(maximum); } public double max(double a,double b,double c) { double k=0; if (a>b && a>c) k=a; else if(b>c) k=b; else k=c; return... Read more »

October 4, 2012 at IST / Language.

Write a program to draw line from corner to corner in JAVA. import javax.swing.JPanel; import java.awt.Graphics; public class MP4 extends JPanel { public void paintComponent(Graphics g) { super.paintComponent(g); int width=getWidth(); int height=getHeight(); for(int i=1;i<=15;i++) { g.drawLine(0,0,width,0); width=width+15; height=height+15; } } }  

October 4, 2012 at IST / Language.

Write a program to add two two number in JAVA import javax.swing.JOptionPane; public class MP3 { public static void main(String args[]) { String n1=JOptionPane.showInputDialog("Enter the 1 st number."); String n2=JOptionPane.showInputDialog("Enter the 2 nd number."); double a,b,c; a=Double.parseDouble(n1); b=Double.parseDouble(n2); c=a+b; String message=String.format("the sum of the entered two numbers is %.2f",c); JOptionPane.showMessageDialog(null,message); } }  

October 4, 2012 at IST / Language.

GUI program to show basic input using a dialog box. import javax.swing.JOptionPane; public class MP2 { public static void main(String args[]) { String hobby=JOptionPane.showInputDialog("What is your hobby?"); String message=String.format("Hi i am Piyush and my hobby is %s",hobby); JOptionPane.showMessageDialog(null,message); } }  

October 4, 2012 at IST / Language.

Binary operations in PHP are a bit strange. Since PHP was originally a templating layer for C code, it still has many of those C-isms. Lots of the function names map directly to C-level APIs, even if they work a bit differently sometimes. For example, PHP’s strlen maps directly to STRLEN(3), and there are countless... Read more »

September 26, 2012 at IST / Language, Web Development.

Moving from ActionScript 2 to ActionScript 3 forces us developers to change some of the habits we have been practicing for quite some time. Recently I had the opportunity to work with XML and ActionScript 3. I soon realized that things had changed – I felt like a n00b as I attempted to parse my... Read more »

September 25, 2012 at IST / Language, Web Development.