#23 Function with Parameters in Java | In Tamil | Java Tutorial Series | Error Makes Clever

Поделиться
HTML-код
  • Опубликовано: 29 ноя 2024

Комментарии • 62

  • @mohamedashfak8452
    @mohamedashfak8452 6 месяцев назад +19

    1st viewer from sri lanka 🇱🇰❤

  • @PreethiSiva-gb3qs
    @PreethiSiva-gb3qs 4 месяца назад +14

    Bro...ungala nambi thn irukom..neenga theivam broo❤

  • @pusparajravishankar
    @pusparajravishankar 6 месяцев назад +14

    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);

    }

    }

    • @suryas-l7z
      @suryas-l7z 3 месяца назад +1

      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

    • @suryas-l7z
      @suryas-l7z 3 месяца назад

      divison ku mattum float use panna answer acuurate ah varum division ku mattum float use pannalam

    • @zero4one-A13
      @zero4one-A13 2 месяца назад

      ​@@suryas-l7zhey bro avaru questions la sub and multiple and div etha name ah function create panna sollirukaru so avanga panni comment pannirukanga

    • @suryas-l7z
      @suryas-l7z 2 месяца назад

      @@zero4one-A13 oh ok bro

  • @prachu3110
    @prachu3110 Месяц назад

    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);
    }
    }

  • @madhanarjun4767
    @madhanarjun4767 2 месяца назад +1

    //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);
    }
    }

  • @sivaram7690
    @sivaram7690 26 дней назад

    //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);
    }
    }

  • @ManiMani-t3o5r
    @ManiMani-t3o5r 18 дней назад +1

    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);
    }
    }

  • @vinothinis307
    @vinothinis307 6 месяцев назад +3

    Bro pls make video daily for this 🙏

  • @umasankari5226
    @umasankari5226 4 месяца назад

    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);
    }
    }

  • @KumaresanDurairaj-r1z
    @KumaresanDurairaj-r1z 2 месяца назад

    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);

    }
    }

  • @22Editz-zo2uy
    @22Editz-zo2uy 2 месяца назад

    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);
    }
    }

  • @harath2048
    @harath2048 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);
    }
    }

  • @ak_lyrics_0034
    @ak_lyrics_0034 3 месяца назад +1

    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):
    }
    }

  • @hamshidhan6279
    @hamshidhan6279 Месяц назад

    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);
    }
    }

  • @JANANIVAECstudent
    @JANANIVAECstudent 2 месяца назад

    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);

    }}

  • @pachaiyappans582
    @pachaiyappans582 4 месяца назад

    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);

    }

    }

  • @lazarus6779
    @lazarus6779 5 дней назад

    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);
    }
    }

  • @themovietone7234
    @themovietone7234 6 месяцев назад +1

    bro make a video on opps concepts pls

  • @kannancutz
    @kannancutz 2 месяца назад

    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);
    }}

    • @kannancutz
      @kannancutz 2 месяца назад

      Ithu crt ta like podungha

  • @jkstudio4807
    @jkstudio4807 3 месяца назад

    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);
    }
    }

  • @Code_With_Gowtham
    @Code_With_Gowtham 6 месяцев назад +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);
    }
    }

  • @VidyasriDhanasekaran-kj4yd
    @VidyasriDhanasekaran-kj4yd 3 месяца назад

    நடு கடலில் vittu senral apadi java video complete panu bro

  • @subashinin4389
    @subashinin4389 4 месяца назад

    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);
    }
    }

  • @jananimanikandan3131
    @jananimanikandan3131 2 месяца назад

    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());
    }}

  • @sarankavin2010
    @sarankavin2010 4 месяца назад

    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

  • @SanthoshKumar-he2rl
    @SanthoshKumar-he2rl 3 месяца назад

    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 😉

  • @maridurai117
    @maridurai117 6 месяцев назад +3

    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);
    }
    }

  • @jayasuryas.m6639
    @jayasuryas.m6639 4 месяца назад

    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);
    }
    }

  • @santhoshsundarmurthy4567
    @santhoshsundarmurthy4567 2 месяца назад +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);
    }
    }

  • @MANOJSURK21CS120
    @MANOJSURK21CS120 3 месяца назад +2

    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();
    }
    }

  • @dhaneshkumar8922
    @dhaneshkumar8922 3 месяца назад

    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);
    }
    }

  • @KumarMS710
    @KumarMS710 4 месяца назад

    Bro error varuthu bro
    Store.java:10: error: ')' expected
    Obj1.sum(num1:10,num2:2);
    Bro intha maari error varuthu 👆
    Please help pannunga 🙏🏻🤌

    • @sinchuc
      @sinchuc 3 месяца назад +1

      Call panrapo num1 and num2 nu parameters podathinga....just numbers matum kudunga...avrku athu defaulta varuthu nu sonnaru

  • @KarthikA-h2y
    @KarthikA-h2y 4 месяца назад

    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);
    }
    }

  • @AishwaryaLakshmi15
    @AishwaryaLakshmi15 3 месяца назад

    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);
    }

    }

  • @mohanakanna.r6448
    @mohanakanna.r6448 5 месяцев назад

    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();
    }
    }

  • @afridemaz
    @afridemaz 6 месяцев назад

    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);
    }
    }