Posts

Showing posts with the label JAVA

How to make C program to convert Fahrenheit into Celsius

How to make C program to convert Fahrenheit into Celsius Temperature conversion formula Temperature conversion formula from degree Celsius to Fahrenheit is given by - Celsius = 5/9(Farenhite - 32) The logic to convert temperature from Celsius to Fahrenheit The logic of temperature conversion exists in converting the mathematical formula to C expression. You just need to convert mathematical formula of temperature in C language. Rest is simple input/output. Below is the step by step descriptive logic to convert temperature from degree Celsius to Fahrenheit. Input temperature in Celsius from the user. Store it in some variable say  celsius . Apply formula to convert the temperature to Fahrenheit i.e. fahrenheit = (celsius * 9 / 5) + 32 Print the value of  Fahrenheit .                  Program to convert temperature from Celsius to Fahrenheit /** * C program to convert temperature from degree celsius to ...
Image
Space Intruders Game In Java Game Source code and the file is given below :  NOTE: Better to open the file in Netbeans  IDE. Download the file from HERE Comment below for any queries or suggestion  Thanks

Brick Breaker Game in JAVA

Image
Brick Breaker Game in JAVA How to make a BrickBreaker game? 1. Create a new project and name it BrickBreaker and paste the source code which is given below. import javax.swing.JFrame; public class BrickBreaker { public static void main(String[] args) { JFrame obj = new JFrame(); Gameplay gameplay = new Gameplay(); obj.setBounds(10,10,700,600); obj.setTitle("BrickBreaker"); obj.setResizable(false); obj.setVisible(true); obj.setDefaultCloseOperation(JFrame. EXIT_ON_CLOSE ); obj.add(gameplay); } } 2. Creat new class two new class and name it "Gameplay" & "MapGentrator" as shown below After creating these class paste source code which is given below respectively. For Gameplay class. import javax.swing.JPanel; import javax.swing.Timer; import java.awt.Graphics2D; import java.awt.Rectangle; import java.awt.Graphics; import java.awt.Color...