Skip to main content

Posts

Showing posts from December, 2020

FEATURED POST

Why the World is Running Out of Computers

Write a program to create a moving string by applet.

 Write a program to create a moving string by applet. import java.applet.Applet; import java.awt.*; import java.awt.event.*; public class MovingString extends Applet implements Runnable { String msg="Hey it's me Gargi....";       Thread t=null;       public void init()       {       setBackground(Color.cyan);                   setBackground(Color.red);                   t=new Thread(this);                   t.start();       }       public void run()       {             ...

Develop an applet that receives an integer in one text field,and computes its factorial value and return it in another text field, when the button named “Compute” is clicked.

 Develop an applet that receives an integer in one text field,and computes its factorial value and return it in another text field, when the button named “Compute” is clicked. import java.awt.*; import java.awt.event.*; import java.applet.*; public class Factorial extends Applet implements ActionListener {     Label l1,l2; TextField t1,t2;     Button com;     //int n,i,fact=0;     public void init()     {          l1=new Label("Enter a no.");         add(l1);         l2=new Label("Factorial");         add(l2);         t1=new TextField(10);         add(t1);         t2=new TextField(10);         add(...

Write a code to create a page which will be able to do the following task:  ADD  SUBTRACT  MULTIPLY  DIVIDE

  Write a code to create a page which will be able to do the following task: Ø ADD Ø SUBTRACT Ø MULTIPLY Ø DIVIDE                                                            import java.awt.*; import java.awt.event.*; import java.applet.*; public  class Calculator extends Applet implements ActionListener {                                                  Label l1,l2; TextField t1,t2,t3;     Button add1,sub,mul,div;     public void init()     {         l1=new Label("First No");  ...

Write a java program to create an abstract class named Shape that contains two integers and an empty method named printArea().

Write a java program to create an abstract class named Shape that contains two integers and an empty method named printArea(). Provide three classes named Rectangle, Triangle and Circle such that each one of the classes extends the class Shape. Each one of the classes contain only the method printArea( ) that prints the area of the given shape. import java.util.*; class Demo{     public static void main(String ts7[]){         int ch;         Rectangle ob1=new Rectangle();         Triangle ob2=new Triangle();         Circle ob3=new Circle();         Scanner sc=new Scanner(System.in);         System.out.println("Enter:\n1.Rectangle\n2.Triangle\n3.Circle\nEnter your Choice:"); ch=sc.nextInt();         switch(ch){ ...

Create a base class called “Vehicle” that stores number of wheels and speed.

  Create a base class called “Vehicle” that stores number of wheels and speed. Create the following derived classes: Ø “Car” that inherits “Vehicle” and also stores number of passengers. Ø “Truck” that inherits “Vehicle” and also stores the load limit. Write a main() function to create objects of these classes and display all the information about Car and Truck. Also, compare the speed of the two vehicles, Car and Truck and display “faster” or “slower” if Car is faster or slower than Truck. import java.util.*; class Vehicle{   int wheels;   double speed; } class Car extends Vehicle{   int pass;   void input(){    Scanner sc=new Scanner(System.in); System.out.println("Enter the car's details:\nNo. of wheels:");    wheels=sc.nextInt(); System.out.println("Speed of Car(Km/hr):");    speed=sc.nextDouble(); System.out.println("No. of passengers:");    pass=sc.nextInt(); } void display(){ ...

PATTERN 7

 /* 2 4 2 4 2 4 2 4 */ #include<stdio.h> int main() { int i,j; for(i=1; i<=4; i++) { for(j=1; j<=4; j++) { if(j%2 == 0) printf("%d",j); } printf("\n"); } return 0; }

PATTERN 6

 #include<stdio.h> int main() { int n = 3, i, j; for(i=1; i<=n; i++) { for(j=i; j<=n; j++) printf("%d", i); printf("\n"); } return 0; }

PATTERN 5

 #include <stdio.h> int main() {    int i, space, rows, k = 0;    printf("Enter the number of rows: ");    scanf("%d", &rows);    for (i = 1; i <= rows; ++i, k = 0) {       for (space = 1; space <= rows - i; ++space) {          printf("  ");       }       while (k != 2 * i - 1) {          printf("* ");          ++k;       }       printf("\n");    }    return 0; }

PATTERN 4

 /*  12345 1234 123 12 1    */ #include<stdio.h> int main() { int n; scanf("%d", &n); for(int i=n; i>=1; i--) { for(int j=1; j<=i; j++) { printf("%d", j); }printf("\n"); } return 0; }

PATTERN 3

 #include <stdio.h> int main() {    int i, j;    char input, alphabet = 'A';    printf("Enter an uppercase character you want to print in the last row: ");    scanf("%c", &input);    for (i = 1; i <= (input - 'A' + 1); ++i) {       for (j = 1; j <= i; ++j) {          printf("%c ", alphabet);       }       ++alphabet;       printf("\n");    }    return 0; }

PATTERN 2

 /*   1 12 123  */ #include<stdio.h> int main() {           int n; scanf("%d", &n); for(int i=1; i<=n; i++) { for(int j=1; j<=i; j++) { printf("%d", j); }printf("\n"); }      return 0; }

PATTERN 1

#include<stdio.h> int main() { int n; scanf("%d", &n); for(int i= 0; i<n; i++) {                for(int j=0; j<i; j++) { printf("*"); }printf("\n"); } return 0;    }         

अधिकतम ट्रैफ़िक के लिए अपनी पोस्ट ऑप्टिमाइज़ करने के लिए दृष्टिकोण

          अपने ब्रांड जागरूकता और वेब ट्रैफ़िक को बढ़ाने के लिए एसईओ को पहचानना बहुत महत्वपूर्ण है और यह एसईओ विशेषज्ञ बनने में भी मदद कर सकता है।  सर्च इंजन ऑप्टिमाइजेशन के शीर्ष पर बने रहने से अध्ययन और प्रयोग में भी काफी मदद मिलती है।  Google के एल्गोरिदम लगातार अपडेट किए जाते हैं, इसलिए सबसे महत्वपूर्ण जानकारी के साथ जुड़े रहना महत्वपूर्ण है। आज की तेजी से बदलती दुनिया में, एसईओ विशेषज्ञों की रणनीतियाँ एक झटके में बदल सकती हैं और सबसे खराब घटक यह है कि आप इसे नहीं पहचान सकते हैं।  1. सरल और आसान कीवर्ड  सुनिश्चित करें कि आपके लेख के लिए आपके द्वारा चुने गए कीवर्ड आसान हैं।  आपके खोजशब्द जितने कठिन हैं, उससे भी अधिक प्रतिस्पर्धियों का आपको सामना करना पड़ेगा।  एक खोजशब्द वाक्यांश चुनने के लिए एक सामान्य नीति वह है जो वेब ट्रैफ़िक की व्यावहारिक मात्रा में आती है।  यह एक प्रतिस्पर्धी खोज वाक्यांश नहीं होना चाहिए।  पूरी तरह से मुफ्त डिवाइस उपलब्ध हैं जो आपको किसी विशेष खोज वाक्यांश के समस्या स्तर को निर्धारित करने की अनुमति...