Address
:
[go:
up one dir
,
main page
]
Include Form
Remove Scripts
Session Cookies
Open navigation menu
Close suggestions
Search
Search
en
Change Language
Upload
Sign in
Sign in
Download free for days
0 ratings
0% found this document useful (0 votes)
12 views
10 pages
Chapter 3
This are the notes of chapter 3 of class 10th icse
Uploaded by
sureshyadav4612
AI-enhanced title
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here
.
Available Formats
Download as PDF or read online on Scribd
Download
Save
Save chapter 3 For Later
0%
0% found this document useful, undefined
0%
, undefined
Embed
Share
Print
Report
0 ratings
0% found this document useful (0 votes)
12 views
10 pages
Chapter 3
This are the notes of chapter 3 of class 10th icse
Uploaded by
sureshyadav4612
AI-enhanced title
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content,
claim it here
.
Available Formats
Download as PDF or read online on Scribd
Carousel Previous
Carousel Next
Download
Save
Save chapter 3 For Later
0%
0% found this document useful, undefined
0%
, undefined
Embed
Share
Print
Report
Download now
Download
You are on page 1
/ 10
Search
Fullscreen
» pifterentiate between formal parameter and 1 ctual parameter. write @ function prototype of the following ‘A. function PosChar which takes a string argument and a character argument and returns ‘an integer value. (ICSE 2016) 9 (id 1 what ae the two way of invoking functions? : (ICSE 2017) 1 write the prototype of function ‘check’ which takes 11 vir integer as an argument and returns a character. (ICSE 2018) 1.2. state aditference between call by value and call by "Teferenice. (ICSE 2019) 1.3. How are the following data types passed to a function ? + Primitive + Reference (ICSE 2005) 14. Explain the function of return statement in Java programming. (ICSE 2006) 15. The access modifier that gives least accessibility is : (2) private (b) public (6) protected (d) package. (ICSE 2022) 16. The keyword which indicates that the method returns no value : (@) public () static (©) void (@) abstract (ICSE 2022) 17. Write a function prototype of the following : (@) A function check which receives a character ch and an integer n and returns true or false. (b) A function abc that returns a double value and three parameters one of integer, one of float and cone of double data type. (©) A function ‘test’ that returns true or false and ‘takes an integer variable and a character variable as its argument. (b) A static method named ‘calculator’ that accepts ‘two short type variables as its arguments and , returns an integer value, (@) A function ‘divide’ that takes two double values as formal parameters and returns the quotient of double type (fA function ‘test’ that takes one character value and ‘one string value and does nat return any value.felon a ak | floats" takes three values as argument byte float and Short. Method argument a ‘sort’ that takes two values aS string array and an integer value and C088 Not return any value. (0) A method ‘convert that takes two objects of class _. Sent’ and returns a string value. A static method ‘CHARAT’ that takes two values imdunetion argument a character array and an integer value and returns a character value. 18. Give 4 met CUtDut of the following program segment (function) also write vihat ‘mathematical f ii
y) K=x-y; else Yay~x + System.out.printino); if 40 and 18 are Passed to the function. (c) void func3 (char c) if System.out.printin((int) c); t if ‘w' is passed to c. (d) void func4(String a, String b) { if(a.compareTo (b)>0) System.out.printin(a); else System.out.printin(b); } if “AMIT" and “AMITABH” are passed to the function. (e) void func5(int n, int d) while(n > 1)ee Ee te values as argument byte feve and takes three float and Short, (ha Method argument a sti does not retu Wa Method ‘co ‘sent’ and ett QA static Met a8 function integer vaiy 8. Give the out ing program segment (function) acd oe ie ied “mathematical is ‘sort’ that takes two values @ ring array and an integer value and In any value. nvert’ that takes two objects of class ums a string value. hod ‘CHARAT? that takes two valued argument a character array and al 1@ and returns a character value. ) y/Stem.out pint G+"; if 10 is Passed to x, (b) He func2 (int x, int y) while (xlsy) sf if > y) X=X~y; else yx : pstom.out printing if 40 and 18 are Passed to the function. (C) void func3 (char c) uF System.out, Printin((int) c); } if ‘w' is passed to c. (d) void func4(String a, String b) { if(a.compareTo (b)>0) ‘System.out.printin(a); else System.out.printin(b); } if “AMIT" and “AMITABH” are Passed to the function. (e) void func&(int n, int d) while(n > 1) { if(n%d==0)a : { gyste™-0' nen /di I else d+ } } if 24 (p int func6(int a int b) ut.printin(d+ “"); and 2 are passed to the function. int an, 8: Ki if (@< D) an=k; while(an%s!=0) ant=k; return an; } if7 and 5 is passed as function argument. (g) boolean func7(int a, int b) boolean c=false; while(a>1 && b>1) return c; : if 27 arid 39 is passed as function argument. (h) int func&(int x, int y) return p; } if 5 and 3 are passed as function argument.'Ss.length(); i+4) tempss.¢ =S.charAt(i) : return iene (i)stemp; } fl i *Programming» argumene "8" is passed as the function {) void f i { WtelO(String a, siring by 1 eHatHO > lengthy Syst : fe “™-out. printin(a.compareTolgnoreCase(b)); else at SEM out print compareTelgnoreCaselel } if PROGRES: S. ; unction arg and PROGRESSIVE is Passed as jument. 19. (a) in the given function prototype Public int add (intx, inty) \ lo © Name the different Components of the function Prototype numbered 1,2, 3,4. (b) State the difference betw and function signature. 20. (a) Which of the following return statements are invalid ? Give reason. (i) return (s, p); (ii) return (m — n); ii) return (s); (iv) return (m) — return (n); (b) State any two features of return statement. een function prototype 21. Debug the errors and rewrite the following function prototypes : (a) int add(a, b) (b) float product(a, int y) (c) String test(char [ 1, int ) (d) double operate(int a, float=4.5) (@) float sum(x, 7 a Jean test(al 1, char) pou compute tee double b) ic public char a (vo 1 input at a=2.5f, float b=a) ae atath(double a, double b)ere sall tha on Public i ie yw " van ty Public yh wie a main() function to call the given functions state's X of £125 tata; return a*a*a} } } 23. Why is the main() method in Java always declared as static ? 24. Identify the type of the following functions pure or impure. : (a) void max (int a, int b) int temp=a; a=b; b=temp; System. out. printin(ay""+-b); (b) void sort (int a (1, int n) { for (int i=0; i
ate { int temp=a [j); aljl=a [j+1) a li+1] = temp; } } } a a “Read the given segments of program and a © questions that follow : Class Record { Public static void method (String x) {~~eputer Applicati Ions (Ig; Ey pores ied Methods write down the statements 22 Wetic void Main() function ts cae seq they Jass X. 7 ofcl fue class X ons int a; int square( ) { return a*a; } static int cube ( ) { return a*a*a; } } 23. Why is the main() method whys th in Java aays ela 24. Identify the type of the fal ic a 1 following functions pure or (a) void max (int a, int b) { int temp=a; a=b; b=temp; ‘System.out.printin(a+*"+b); } (b) void sort (int a 0, int n) { for (int i= { for (int { if (a (> ale) { int temp=a UU alia fj +1) a [jl] = temp: } + } we } progr and a 25. Read the given seamen's ° the questions that flow (a) class Record 0 ing static void ethos ot ( public { _—_170 | (0); char a=x.charAt “ys char charAt (x.length0 Di intczat++-—Di yy a Dy system.out.printin(& ete , iter the + i in a, B64 (i) What value will be stores omputer” as the method gets executed method argument. | (i) Define the main method which calls method (). Itant (iii) Modify method ( ) so ‘that the resul returned by the function. (b) class My Class the above cis private short roll_n0; private long cand_code; private String cand_name; method of the class that displays d_code and roll_no, the gs “Rohan”, 2005123 } (i) Define a static the cand_name, can values being assigned and 20 respectively. (ii) Write a Java statement defined method in a non static-method. (c) class Mathematics { int a, b; public static int operate ( ) { intc=aH + Ha-a; intd=cH + b— return d; that calls the above -static method and a } () Write a single statement that call singles Is the meth un Be le sta void main() a il) What happens if an object ‘ob’ of y cla Mathematics directly invokes the variable ¢ and d in another static method as follows «in etn ob + 0b ii) The given function is a uncti Theshen fu n impure function, State (iv) What will be the final resultant values in a, b and d, if a and b ate initialized as § and 10 respectively? ee (@) double calculatetint x, double y) return x * y, } calculate(double x, double y) return wy; }oe @ state Taiven ft @ wt cau usi Static method. : -.y write the Java prototype for the function ca Wate to return a double result and accepts three float parameters. iy) Is the prototype void calculate (float a, float b) ‘ valid for the given functions. Give reason. (e) public static int calculate (int aC) function. Java statements to invoke the ing actual parameter in a a (int =O; i
0) return true; else return false; }eth” 172 port ‘oid is the 4 (y Wie one statement that clined in another _norrs ; ‘on tot getvaluel) of the same ee ‘9 above functi Ci What wil be the ouPT ot tu? set func(20) and what v i” oroara follow! 26. Find the errors in the is and write the correct statemen' (a) static add (void) int a; b; a=2} and an ; system.out.printin(a+ +b) il dD (b) hablo static Void sentence (string x C { int y; y=x-length (); System.out.printin(y); } ' (c) double producttint p, 4) { } (d) public class Remainder { private int a, b; Remainder (int x, y) { aax%ys public static void main( ) Remainder rem=new Remainder(); © di class Name int squareroot (int a, int b) eum math.sart (a ~ b); public static void main () { eS Te (8, 15)); } (f) String method (String n) string x = name(); public static void main() String a= “India”; String x=-method(); }
You might also like
Solved 2023 Question Paper ICSE Class 10 Computer Applications
PDF
No ratings yet
Solved 2023 Question Paper ICSE Class 10 Computer Applications
24 pages
Tutorial 7 TTTK1114 UKM
PDF
100% (1)
Tutorial 7 TTTK1114 UKM
11 pages
X - PreBoard 2023 Solved
PDF
No ratings yet
X - PreBoard 2023 Solved
10 pages
Sample 3 Oswaal
PDF
No ratings yet
Sample 3 Oswaal
5 pages
First Term Assessment Computer Applications: Section A Any Four Section B
PDF
No ratings yet
First Term Assessment Computer Applications: Section A Any Four Section B
4 pages
Georges 2024 X
PDF
No ratings yet
Georges 2024 X
3 pages
Cpsc112A Asg2 Pratibha 10134087
PDF
No ratings yet
Cpsc112A Asg2 Pratibha 10134087
9 pages
Specimen Papers
PDF
No ratings yet
Specimen Papers
19 pages
Arihant - Computer 12 Icse Class 10
PDF
No ratings yet
Arihant - Computer 12 Icse Class 10
5 pages
Model Test Paper 9 (Unsolved) : Section)
PDF
No ratings yet
Model Test Paper 9 (Unsolved) : Section)
4 pages
Computer Practise Paper 1 (Solved)
PDF
No ratings yet
Computer Practise Paper 1 (Solved)
12 pages
JAVA Functions Based Programs Frank Function
PDF
No ratings yet
JAVA Functions Based Programs Frank Function
7 pages
Function
PDF
No ratings yet
Function
3 pages
MCQ and Logical 4 Prelims Ans in Last Page
PDF
No ratings yet
MCQ and Logical 4 Prelims Ans in Last Page
10 pages
First Term Assessment Computer Applications: Bombay Scottish School, Mahim
PDF
No ratings yet
First Term Assessment Computer Applications: Bombay Scottish School, Mahim
4 pages
Georges U-2 Preboard 2023-24
PDF
No ratings yet
Georges U-2 Preboard 2023-24
4 pages
Computer 2023
PDF
No ratings yet
Computer 2023
20 pages
CMS PRE-BOARD Question Paper Class 10th Computer
PDF
No ratings yet
CMS PRE-BOARD Question Paper Class 10th Computer
9 pages
Key Answers Kisa Preparatory Computer Applications
PDF
40% (5)
Key Answers Kisa Preparatory Computer Applications
9 pages
Arihant - Computer 15 TH Sample Paper Icse Class 10
PDF
No ratings yet
Arihant - Computer 15 TH Sample Paper Icse Class 10
5 pages
ICSE Class 10 Computer Applications
PDF
60% (5)
ICSE Class 10 Computer Applications
68 pages
Paper Class 10th 2024-25
PDF
No ratings yet
Paper Class 10th 2024-25
6 pages
CPK
PDF
No ratings yet
CPK
5 pages
Com 2016
PDF
No ratings yet
Com 2016
13 pages
Specimen 2025
PDF
No ratings yet
Specimen 2025
12 pages
Icse Sample Paper-1 For Computer Applications
PDF
100% (1)
Icse Sample Paper-1 For Computer Applications
5 pages
ICSE 2015 Computer Applications Solved Paper
PDF
No ratings yet
ICSE 2015 Computer Applications Solved Paper
17 pages
Kisa Preparatory Paper Computer Applications
PDF
No ratings yet
Kisa Preparatory Paper Computer Applications
6 pages
ICSE Computer Solved Paper 2015
PDF
No ratings yet
ICSE Computer Solved Paper 2015
6 pages
ICSE COMPUTER APPLICATIONS CLASS 10 Important Questions
PDF
100% (1)
ICSE COMPUTER APPLICATIONS CLASS 10 Important Questions
24 pages
SXCS Computer Applications 2024 Rehearsals
PDF
No ratings yet
SXCS Computer Applications 2024 Rehearsals
4 pages
X Practice Paper
PDF
No ratings yet
X Practice Paper
10 pages
ICSE 2nd PB 2023-24
PDF
No ratings yet
ICSE 2nd PB 2023-24
8 pages
10TH Icse 2023
PDF
No ratings yet
10TH Icse 2023
9 pages
Mock Test 1 2024-25
PDF
No ratings yet
Mock Test 1 2024-25
6 pages
Frank 1
PDF
No ratings yet
Frank 1
10 pages
Compt 1
PDF
No ratings yet
Compt 1
5 pages
COMPUTER APPLICATIONS Prac
PDF
No ratings yet
COMPUTER APPLICATIONS Prac
9 pages
Icse 2023 - 861 Cta
PDF
No ratings yet
Icse 2023 - 861 Cta
8 pages
CBS Computer Application
PDF
No ratings yet
CBS Computer Application
5 pages
Class 10 - Practice Paper 2 - 2022-23 - Comp App
PDF
No ratings yet
Class 10 - Practice Paper 2 - 2022-23 - Comp App
3 pages
ICSE 10th Board Exam
PDF
No ratings yet
ICSE 10th Board Exam
4 pages
PreBoard 02
PDF
No ratings yet
PreBoard 02
6 pages
Group 1 2 3 4 5 7 Model 1 2025 20 01
PDF
No ratings yet
Group 1 2 3 4 5 7 Model 1 2025 20 01
5 pages
42ee4513-7a82-4221-bc3a-ceeb1fcfe462
PDF
No ratings yet
42ee4513-7a82-4221-bc3a-ceeb1fcfe462
8 pages
JNS Ca Prelim 1 Paper
PDF
No ratings yet
JNS Ca Prelim 1 Paper
9 pages
Computer Applications JML
PDF
No ratings yet
Computer Applications JML
7 pages
X-CTA-Second-Prep QP-24-25
PDF
No ratings yet
X-CTA-Second-Prep QP-24-25
8 pages
2018 Icse
PDF
No ratings yet
2018 Icse
23 pages
Mock 6
PDF
No ratings yet
Mock 6
5 pages
Preboard 1 X
PDF
No ratings yet
Preboard 1 X
6 pages
ICSE Question Paper Computer Application 2012
PDF
0% (1)
ICSE Question Paper Computer Application 2012
16 pages
10 Computer Applications
PDF
No ratings yet
10 Computer Applications
6 pages
10th Computer FLT Paper 22.09.2024
PDF
No ratings yet
10th Computer FLT Paper 22.09.2024
6 pages
10 Computer Applications HY 23-24
PDF
No ratings yet
10 Computer Applications HY 23-24
7 pages
861 Cta - 2017 PDF
PDF
No ratings yet
861 Cta - 2017 PDF
6 pages
10 ICSE - Midterm
PDF
No ratings yet
10 ICSE - Midterm
4 pages
(2012) ICSE Computer Applications Question Paper
PDF
100% (1)
(2012) ICSE Computer Applications Question Paper
6 pages