public class coding21{ void sum(int a, int b) { System.out.println(a+b); } void sub(int a, int b) { System.out.println(a-b); } void mul(int a, int b) { System.out.println(a*b); } void div(int a, int b) { System.out.println(a/b); } public static void main(String[] args) { coding21 obj1 = new coding21();
neenga ivlo perusa poda theva illa vro public class store{ void soap(int num1,int num2){ System.out.println(num1+num2); System.out.println(num1-num2); System.out.println(num1*num2); System.out.println(num1/num2); } public static void main(String[]args){ store obj1=new store(); obj1.soap(20,30); } } idhu podhum vro
public class math{ void sum (int a , int b) { System.out.println(a+b); } void mul (int a , int b) { System.out.println(a*b); } void div (int a , int b) { System.out.println(a/b); }
public static void main(String args[]) { math obj1 = new math(); obj1.sum(5,5); obj1.mul(5,2); obj1.div(100,10); } }
Public class maths{ Void add(double n,n1) System.out.println(n+n1); System.out.println(n-n1); System.out.println(n/n1); System.out.println(n*n1); } Public static void main (String args[]) { Maths num =new maths(); add .num(10,2); }}
public class Sum{ void sum1(int num1,int num2) { System.out.println("The Add Value Of Num1&Num2 :"); System.out.println(num1+num2); } void sum2(int num1,int num2) { System.out.println("The Sub Value Of Num1&Num2 :"); System.out.println(num1-num2); } void sum3(int num1,int num2) { System.out.println("The Mul Value Of Num1&Num2 :"); System.out.println(num1*num2); } void sum4(int num1,int num2) { System.out.println("The Div Value Of Num1&Num2 :"); System.out.println(num1/num2); } public static void main(String args[]) { Sum obj = new Sum(); obj.sum1(2,5); obj.sum2(2,5); obj.sum3(2,5); obj.sum4(2,5); } }
public class Sum{ int a = 10; int b =2; int add(){ int add =a+b; return add; } int sub(){ int sub =a-b; return sub; } int mul(){ int mul =a*b; return mul; } int div(){ int add =a/b; return div; } public static void main (String[] args){ Sum sm = new Sum(); System.out.println(sm.add()); System.out.println(sm.sub()); System.out.println(sm.mul()) ; System.out.println(sm.div()); }}
package Aval; import java.util.Scanner; public class Store { public void add(int a, int b) { System.out.println("The additon is:"+" "+(a+b)); } public void sub(int a, int b) { System.out.println("The subtraction is:"+" "+(a-b)); } public void mul(int a, int b) { System.out.println("The multiplication is:"+" "+(a*b)); } public void div(int a, int b) { System.out.println("The division is:"+" "+(a%b)); } public static void main(String[] args) { Store sr=new Store(); Scanner rs=new Scanner(System.in); System.out.println("Enter the first number"); int a=rs.nextInt(); System.out.println("Enter the second number"); int b=rs.nextInt(); sr.add(a,b); sr.sub(a,b); sr.mul(a,b); sr.div(a,b); } } I hope u guys like this 😉
import java.util.Scanner; public class addfuc{ void simple(int a, int b){ int c = a*b; float num = (a/b); int e = a-b; System.out.println(c); System.out.println(num); System.out.println(e); } public static void main(String[] args){ addfuc ne = new addfuc(); Scanner scan = new Scanner(System.in); System.out.println("Enter a "); int a = scan.nextInt(); System.out.println("Enter b "); int b = scan.nextInt(); ne.simple(a,b); } }
public static void main(String[] args) { // TODO Auto-generated method stub Scanner sc=new Scanner(System.in); System.out.println("enter the value of a: "); int a=sc.nextInt(); System.out.println("enter the value of :b "); int b=sc.nextInt();
import java.util.Scanner; public class eg19{ void add(int a,int b){ int add = a + b; System.out.println("The addition of a and b : "+add); } void sub(int a, int b){ int sub = a - b; System.out.println("The subraction of a and b : "+sub); } void mul(int a, int b){ int mul = a * b; System.out.println("The multiplication of a and b : "+mul); } void div(int a, int b){ int div = a / b; System.out.println("The division of a and b : "+div); } public static void main(String[] args) { eg19 dang = new eg19(); Scanner jok = new Scanner(System.in); System.out.println("Enter the number of a : "); int h = jok.nextInt(); System.out.println("Enter the number of b : "); int k = jok.nextInt(); dang.add(h, k); dang.sub(h, k); dang.mul(h, k); dang.div(h, k); } }
package functions; public class Dmas { void sum(int a, int b) { System.out.println("Sum of two numbers is " + (a + b)); } void sub(int a, int b) { System.out.println("Subtraction of two numbers is " + (a - b)); } void div(int a, int b) { System.out.println("Division of two numbers is " + (a / b)); } void multi(int a, int b) { System.out.println("Multiplication of two numbers is " + (a * b)); } public static void main(String[] args) { int a = 30; int b = 20; Dmas obj = new Dmas(); obj.sum(a, b); obj.sub(a, b); obj.div(a, b); obj.multi(a, b); } }
1st viewer from sri lanka 🇱🇰❤
Hi bro ❤
Bro...ungala nambi thn irukom..neenga theivam broo❤
Fact 🎉
public class coding21{
void sum(int a, int b)
{
System.out.println(a+b);
}
void sub(int a, int b)
{
System.out.println(a-b);
}
void mul(int a, int b)
{
System.out.println(a*b);
}
void div(int a, int b)
{
System.out.println(a/b);
}
public static void main(String[] args)
{
coding21 obj1 = new coding21();
obj1.sum(10,2);
obj1.sub(10,2);
obj1.mul(10,2);
obj1.div(10,2);
}
}
neenga ivlo perusa poda theva illa vro
public class store{
void soap(int num1,int num2){
System.out.println(num1+num2);
System.out.println(num1-num2);
System.out.println(num1*num2);
System.out.println(num1/num2);
}
public static void main(String[]args){
store obj1=new store();
obj1.soap(20,30);
}
}
idhu podhum vro
divison ku mattum float use panna answer acuurate ah varum division ku mattum float use pannalam
@@suryas-l7zhey bro avaru questions la sub and multiple and div etha name ah function create panna sollirukaru so avanga panni comment pannirukanga
@@zero4one-A13 oh ok bro
class Function{
void sub(int a,int b)
{
System.out.println(a-b);
}
void mul(int a,int b)
{
System.out.println(a*b);
}
void div(int a,int b)
{
System.out.println(a/b);
}
public static void main(String[] args){
Function obj1=new Function();
obj1.sub(15,3);
obj1.mul(10,2);
obj1.div(10,4);
}
}
//add,sub,mul,div
public class sum {
void arithmatic(int num1, int num2)
{
System.out.println(num1+num2);
System.out.println(num1-num2);
System.out.println(num1*num2);
}
void div(double num1, double num2)
{
System.out.println(num1/num2);
}
public static void main(String[] args) {
sum obj1 = new sum();
obj1.arithmatic(10,20);
obj1.div(10, 20);
}
}
//The code defines a class OP with several integer variables and a method sum() that performs the following operations:
// +,-,*, /
public class OP{
//int a =10;
// int b=20;
//int c=(a+b);
//int d=(a*b);
//int e=(a-b);
//int f=(a/b);
void sum(int num1,int num2)
{
System.out.println(num1+num2);
System.out.println(num1-num2);
System.out.println(num1*num2);
System.out.println(num1/num2);
}
public static void main(String[] args)
{
OP operation=new OP();
operation.sum(10,20);
}
}
public class Method
{
void sum(int numi, int num2) {
System.out.println(num1+num2);
System.out.println(x:"added value ");
}
void mul(int mul1, int mul2)
{
System.out.println(mul1*mul2);
System.out.println(x:"Multiply value");
}
public static void main(String[] args)
{
Method obj1=new Method(); obj1.sum(23,56);
obj1.mul (34,56);
}
}
Bro pls make video daily for this 🙏
Public class summ{
Void sum(int a,int b)
{
System.out.println (a+b);
System.out.println (a-b);
System.out.println (a%b);
System.out.println (a*b);
}
Public static void main(String args[])
{
Summ obj1=new summ();
Obj1.sum(20,10);
}
}
void sweet(int chandrika, int sooryakala){
System.out.println("Your favorite is here :");
System.out.println(chandrika*sooryakala);
}
void cloth(int lenin, int cargo){
System.out.println("Your favorite cloth :");
System.out.println(lenin%cargo);
}
void perfume(int megestic, int fragrence){
System.out.println("your favorite perfume :");
System.out.println(megestic-fragrence);
}
public static void main(String[] args) {
argument_add_sub_div store = new argument_add_sub_div();
store.cloth(98,35);
store.perfume(78,34);
store.sweet(12,98);
}
}
public class Calculate {
void add(int num1,int num2)
{
System.out.print("Addition: ");
System.out.println(num1+num2);
}
void sub(int num1,int num2)
{
System.out.print("Substraction: ");
System.out.println(num1-num2);
}
void mul(int num1,int num2)
{
System.out.print("Multiplication: ");
System.out.println(num1*num2);
}
void div(int num1,int num2)
{
System.out.print("Divition: ");
System.out.println(num1/num2);
}
public static void main(String[] args) {
Calculate obj1=new Calculate();
obj1.add(20,2);
obj1.sub(20,2);
obj1.mul(20,2);
obj1.div(20,2);
}
}
public class operation{
void sum(int a,int b){
System.out.println(a+b);
}
void sub(int a,int b){
System.out.println(a-b);
}
void mul(int a,int b){
System.out.println(a*b);
}
void div(int a,int b){
System.out.println(a%b);
}
public static void main(String[] args){
operation obj = new operation();
obj.sum(1,2);
obj.sub(10,2);
obj.mul(10,2);
obj.div(10,2);
}
}
Class demo{
Void num(int num1,int num1)
{
System. Out. Print(num1/num2):
}
Public static void main (string[] args)
{
Num() obj1=new num()
Num(20,30):
}
}
public class math{
void sum (int a , int b)
{
System.out.println(a+b);
}
void mul (int a , int b)
{
System.out.println(a*b);
}
void div (int a , int b)
{
System.out.println(a/b);
}
public static void main(String args[])
{
math obj1 = new math();
obj1.sum(5,5);
obj1.mul(5,2);
obj1.div(100,10);
}
}
package limited;
public class addition {
void sub (int q,int a) {
System.out.println(q-a);
}
public static void main(String args[]) {
addition aaa = new addition();
aaa.sub(10,5);
}}
public class functionwithparameter {
void addition(int num1,int num2){
System.out.println("Addition");
System.out.println(num1+num2);
}
void subtraction(int num1,int num2){
System.out.println("subtraction");
System.out.println(num1-num2);
}
void multiply(int num1,int num2){
System.out.println("Multiplication");
System.out.println(num1*num2);
}
void division(int num1,int num2){
System.out.println("Division");
System.out.println(num1/num2);
}
public static void main(String[] args) {
functionwithparameter obj1=new functionwithparameter();
obj1.addition(1500,2000);
obj1.subtraction(50, 900);
obj1.multiply(5,6000 );
obj1.division(70, 1334);
}
}
public class q40 {
void add(int a,int b)
{
System.out.println(a+b);
}
void sub(int a,int b)
{
System.out.println(a-b);
}
void mul(int a,int b)
{
System.out.println(a*b);
}
void div(int a,int b)
{
System.out.println(a/b);
}
public static void main(String[] args) {
q40 obj = new q40();
obj.add(10,1);
obj.sub(10,2);
obj.mul(10,3);
obj.div(10,4);
}
}
bro make a video on opps concepts pls
Public class maths{
Void add(double n,n1)
System.out.println(n+n1);
System.out.println(n-n1);
System.out.println(n/n1);
System.out.println(n*n1);
}
Public static void main (String args[])
{
Maths num =new maths();
add .num(10,2);
}}
Ithu crt ta like podungha
public class Sum{
void sum1(int num1,int num2)
{
System.out.println("The Add Value Of Num1&Num2 :");
System.out.println(num1+num2);
}
void sum2(int num1,int num2)
{
System.out.println("The Sub Value Of Num1&Num2 :");
System.out.println(num1-num2);
}
void sum3(int num1,int num2)
{
System.out.println("The Mul Value Of Num1&Num2 :");
System.out.println(num1*num2);
}
void sum4(int num1,int num2)
{
System.out.println("The Div Value Of Num1&Num2 :");
System.out.println(num1/num2);
}
public static void main(String args[])
{
Sum obj = new Sum();
obj.sum1(2,5);
obj.sum2(2,5);
obj.sum3(2,5);
obj.sum4(2,5);
}
}
public class addtion {
void sum(int a,int b){
System.out.println(a+b);
}
void sub(int a,int b){
System.out.println(a-b);
}
void mul(int a,int b){
System.out.println(a*b);
}
void div(int a,int b){
System.out.println(a/b);
}
public static void main(String[] args) {
addtion operation = new addtion();
operation.sum(20,20);
operation.sub(20,20);
operation.mul(20,20);
operation.div(20,20);
}
}
நடு கடலில் vittu senral apadi java video complete panu bro
public class Maths{
void Add(int n1,int n2)
{
System.out.println("addition:",n1+n2);
}
void sub(int n1,int n2)
{
System.out.println("Subtraction:",n1 - n2);
}
void mul(int n1,int n2)
{
System.out.println("Multiplication:",n1*n2);
}
void Div(int n1,int n2)
{
System.out.println("Division:",n1/n2);
}
public static void main (String [ ] arg){
Maths m1= new Maths();
m1.Add(20,5);
m1.sub(20,5);
m1.mul(20,5);
m1.Div(20,5);
}
}
public class Sum{
int a = 10;
int b =2;
int add(){
int add =a+b;
return add;
}
int sub(){
int sub =a-b;
return sub;
}
int mul(){
int mul =a*b;
return mul;
}
int div(){
int add =a/b;
return div;
}
public static void main (String[] args){
Sum sm = new Sum();
System.out.println(sm.add());
System.out.println(sm.sub());
System.out.println(sm.mul()) ;
System.out.println(sm.div());
}}
import java.util.Scanner;
public class para_sum {
void sum(int a,int b){
System.out.println("num1 is "+a);
System.out.println("num2 is "+b);
System.out.println("sum"+a+b);
System.out.println("sub"+(a-b));
System.out.println("multi"+a*b);
System.out.println("div"+a/b);
}
public static void main(String[] args) {
Scanner scan =new Scanner(System.in);
para_sum obj=new para_sum();
int a= scan.nextInt();
int b= scan.nextInt();
obj.sum(a,b);
}
}
Output
8
4
num1 is 8
num2 is 4
sum 12
sub 4
multi 32
div 2
package Aval;
import java.util.Scanner;
public class Store {
public void add(int a, int b) {
System.out.println("The additon is:"+" "+(a+b));
}
public void sub(int a, int b) {
System.out.println("The subtraction is:"+" "+(a-b));
}
public void mul(int a, int b) {
System.out.println("The multiplication is:"+" "+(a*b));
}
public void div(int a, int b) {
System.out.println("The division is:"+" "+(a%b));
}
public static void main(String[] args) {
Store sr=new Store();
Scanner rs=new Scanner(System.in);
System.out.println("Enter the first number");
int a=rs.nextInt();
System.out.println("Enter the second number");
int b=rs.nextInt();
sr.add(a,b);
sr.sub(a,b);
sr.mul(a,b);
sr.div(a,b);
}
}
I hope u guys like this 😉
import java.util.Scanner;
public class addfuc{
void simple(int a, int b){
int c = a*b;
float num = (a/b);
int e = a-b;
System.out.println(c);
System.out.println(num);
System.out.println(e);
}
public static void main(String[] args){
addfuc ne = new addfuc();
Scanner scan = new Scanner(System.in);
System.out.println("Enter a ");
int a = scan.nextInt();
System.out.println("Enter b ");
int b = scan.nextInt();
ne.simple(a,b);
}
}
❤
import java.util.Scanner;
public class Sum {
void sum(int num1, int num2)
{
System.out.println("Sum:"+ (num1+num2));
}
void sub(int num1, int num2)
{
System.out.println("sub:"+ (num1-num2));
}
void mul(int num1, int num2)
{
System.out.println("Mul:"+ (num1*num2));
}
void div(int num1, int num2)
{
System.out.println("Div:"+ (num1/num2));
}
public static void main(String[]args){
Sum obj1 = new Sum();
obj1.sum(10,2);
Sum obj2 = new Sum();
obj2.sub(10,2);
Sum obj3 = new Sum();
obj3.mul(10,2);
Sum obj4 = new Sum();
obj4.div(10,2);
}
}
class test1
{
void summing(int a,int b)
{
System.out.println(a+b);
System.out.println(a-b);
System.out.println(a*b);
System.out.println(a/b);
}
public static void main(String[] args) {
test1 obj1 = new test1();
obj1.summing(100, 100);
}
}
package MJ;
import java.util.Scanner;
public class parameters {
static void add(int num1,int num2) {
System.out.println("Addition: "+(num1+num2));
}
static void sub(int num1,int num2) {
System.out.println("Subraction: "+(num1-num2));
}
static void mul(int num1,int num2) {
System.out.println("Multiplication: "+(num1*num2));
}
static void div(int num1,int num2) {
System.out.println("Division: "+(num1/num2));
}
public static void main(String[] args) {
// TODO Auto-generated method stub
Scanner sc=new Scanner(System.in);
System.out.println("enter the value of a: ");
int a=sc.nextInt();
System.out.println("enter the value of :b ");
int b=sc.nextInt();
add(a,b);
sub(a,b);
mul(a,b);
div(a,b);
sc.close();
}
}
import java.util.Scanner;
public class eg19{
void add(int a,int b){
int add = a + b;
System.out.println("The addition of a and b : "+add);
}
void sub(int a, int b){
int sub = a - b;
System.out.println("The subraction of a and b : "+sub);
}
void mul(int a, int b){
int mul = a * b;
System.out.println("The multiplication of a and b : "+mul);
}
void div(int a, int b){
int div = a / b;
System.out.println("The division of a and b : "+div);
}
public static void main(String[] args) {
eg19 dang = new eg19();
Scanner jok = new Scanner(System.in);
System.out.println("Enter the number of a : ");
int h = jok.nextInt();
System.out.println("Enter the number of b : ");
int k = jok.nextInt();
dang.add(h, k);
dang.sub(h, k);
dang.mul(h, k);
dang.div(h, k);
}
}
Bro error varuthu bro
Store.java:10: error: ')' expected
Obj1.sum(num1:10,num2:2);
Bro intha maari error varuthu 👆
Please help pannunga 🙏🏻🤌
Call panrapo num1 and num2 nu parameters podathinga....just numbers matum kudunga...avrku athu defaulta varuthu nu sonnaru
package functions;
public class Dmas {
void sum(int a, int b) {
System.out.println("Sum of two numbers is " + (a + b));
}
void sub(int a, int b) {
System.out.println("Subtraction of two numbers is " + (a - b));
}
void div(int a, int b) {
System.out.println("Division of two numbers is " + (a / b));
}
void multi(int a, int b) {
System.out.println("Multiplication of two numbers is " + (a * b));
}
public static void main(String[] args) {
int a = 30;
int b = 20;
Dmas obj = new Dmas();
obj.sum(a, b);
obj.sub(a, b);
obj.div(a, b);
obj.multi(a, b);
}
}
public class calculation {
void sum(int a,int b){
System.out.println(a+b);
}
void subtract(int a,int b){
System.out.println(a-b);
}
void multiply(int a,int b){
System.out.println(a*b);
}
void divide(int a,int b){
System.out.println(a/b);
}
public static void main(String[] args) {
calculation obj=new calculation();
obj.sum(10,34);
obj.subtract(26, 42);
obj.multiply(10, 200);
obj.divide(128, 7);
}
}
import java.util.Scanner;
public class Calculator {
void add(int x,int y){
System.out.println(x+y);
}
void sub(int x,int y){
System.out.println(x-y);
}
void mul(int x,int y){
System.out.println(x*y);
}
void div(int x,int y){
System.out.println(x/y);
}
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int x = sc.nextInt();
int y = sc.nextInt();
Calculator cal = new Calculator();
cal.add(x, y);
cal.sub(x, y);
cal.mul(x, y);
cal.div(x, y);
sc.close();
}
}
public class Main{
void sub(int num1, int num2){
System.out.println(num1 - num2);
}
void mul(int num1, int num2){
System.out.println(num1 * num2);
}
void div(double num1, double num2){
System.out.println(num1 / num2);
}
public static void main(String[] args){
Main obj = new Main();
obj.sub(100, 30);
obj.mul(26, 1034);
obj.div(1237,5);
}
}