0% found this document useful (0 votes)
6 views3 pages

Week2 3

The SWEN20003 workshop focuses on hands-on experience with Java programming using IntelliJ IDEA. Participation is assessed, requiring pre-workshop preparation, attendance, and engagement with workshop questions. Students are encouraged to set up their development environment and complete programming tasks, including creating a triangle and a diamond pattern, while seeking feedback from demonstrators.

Uploaded by

Chow Caihong
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views3 pages

Week2 3

The SWEN20003 workshop focuses on hands-on experience with Java programming using IntelliJ IDEA. Participation is assessed, requiring pre-workshop preparation, attendance, and engagement with workshop questions. Students are encouraged to set up their development environment and complete programming tasks, including creating a triangle and a diamond pattern, while seeking feedback from demonstrators.

Uploaded by

Chow Caihong
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

SWEN20003

Object Oriented Software Development


Workshop 1

Introduction
Welcome to Object Oriented Software Development! These workshops contain practical problems that will
give you hands-on experience designing and implementing programs in Java. Participation is assessed. Each
workshop is worth 1 mark: to be eligible for this mark you must

1. attempt the pre-workshop questions on Ed Lessons


2. attend your enrolled workshop
3. make a reasonable attempt at the given workshop questions
We highly encourage you to also attempt the other problems for each workshop. By consulting with your
demonstrator and getting feedback on your solutions, you will be in a much stronger position for the subject’s
assessment.

If you cannot attend


If for some reason you cannot attend your enrolled workshop in a particular week, please use the Alternative
Workshop Request form (linked on Canvas) to let us know. Do not attend an alternative class without
approval from Shanika or Andrew (via the form). Please try to submit as early as you can so there is
sufficient time to check and approve the request.

Workshop
The focus of this workshop is getting set up with the Java development environment we will use, IntelliJ IDEA.
To download IntelliJ (for Windows, MacOS, or Linux) head to https://www.jetbrains.com/idea/download/
and click the Download button under Community. Install the software after downloading; the default settings
are fine.
To get started with IntelliJ, try compiling a Hello World program following the below steps.
1. When you first open IntelliJ, you’ll see the below screen. Click New Project.

2. Click <No SDK> and select Download JDK.... The default option is fine; wait for it to download and
install, then click Next.
Note: If you have IntelliJ installed on your computer make sure that you are using the Java SDK version
11 or higher.

1
3. Give your project a name, e.g. HelloWorld.

4. Your Java code should go in the src folder of your project. Right-click this folder, and click New → Java
Class.

5. Give your class a name, e.g. Program. Remember the file name needs to match the name of the class in
the code, and class names must start with a capital letter.

6. Add this Hello World code, and press the Play button next to the class name (here the button is green).
Then click Run ’Program.main’. Note: the button may take a minute or two to appear the first time
you run IntelliJ, since it needs to finish setting up the JDK.

2
7. Your program’s output will appear at the bottom of the screen.

Make sure you have set up IntelliJ before continuing with the other problems.

Problems
1. Write a program to print a triangle of some constant size. For example, a triangle of size 5 should look
like this:

#
##
###
####
#####

2. Write a program to print a diamond of some constant odd size. For example, a diamond of size 5 should
look like this:

#
###
#####
###
#

3. Try compiling and running the example code from lectures using IntelliJ.

4. Continue working through the Grok worksheets.

You might also like