
Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Community
Ask the community for help and clear up your study doubts
Discover the best universities in your country according to Docsity users
Free resources
Download our free guides on studying techniques, anxiety management strategies, and thesis advice from Docsity tutors
Information systems➝Database management system engines • Computing methodologies➝Massively parallel and high-performance simulations. This is just an example, please use the correct category and subject descriptors for your submission. The ACM Computing Classification Scheme: http://www.acm.org/about/class/class/2012. Please read the HOW TO CLASSIFY WORKS USING ACM'S COMPUTING CLASSIFICATION SYSTEM for instructions on how to classify your document using the 2012 ACM Computing Classification Sy
Typology: Exercises
1 / 1
This page cannot be seen from the preview
Don't miss anything!
Republic of the Philippines
F. Pimentel Avenue, Brgy. 2, Daet, Camarines Norte – 4600, Philippines Name: Manahan, Mariano Date: September 18, 2021 Course & Block: BSIT- 2 C Subject: IT - 102 Exercises:
1. Write a program to demonstrate static variables, methods, and blocks. public class Demo { static int x = 10 ; static int y; static void func(int z) { System.out.println("x = " + x); System.out.println("y = " + y); System.out.println("z = " + z); } static { System.out.println("Running static initialization block."); y = x + 5 ; } public static void main(String args[]) { func( 8 ); } }
Running static initialization block. x = 10 y = 15 z = 8