Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
programming sem 2 year 1
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
daniel.tang
programming sem 2 year 1
Commits
49980461
Commit
49980461
authored
Jan 27, 2020
by
daniel.tang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Upload New File
parent
97685126
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
41 additions
and
0 deletions
+41
-0
colors1.java
Week 1/Colors/colors1.java
+41
-0
No files found.
Week 1/Colors/colors1.java
0 → 100644
View file @
49980461
package
programmingP2week1
;
import
static
java
.
lang
.
System
.
out
;
public
class
colors1
{
public
static
void
main
(
String
[]
args
)
{
// TODO Auto-generated method stub
colors
yellow
=
new
colors
();
yellow
.
r
=
225
;
yellow
.
g
=
225
;
yellow
.
b
=
0
;
colors
purple
=
new
colors
();
purple
.
r
=
128
;
purple
.
g
=
0
;
purple
.
b
=
128
;
colors
orange
=
new
colors
();
orange
.
r
=
225
;
orange
.
g
=
165
;
orange
.
b
=
0
;
out
.
println
(
"Colors | Red | Green | Blue\n"
+
"---------------------------\n"
+
"Yellow | "
+
yellow
.
r
+
" | "
+
yellow
.
g
+
" | "
+
yellow
.
b
+
" \n"
+
"---------------------------\n"
+
"Purple | "
+
purple
.
r
+
" | "
+
purple
.
g
+
" | "
+
purple
.
b
+
"\n"
+
"---------------------------\n"
+
"Orange | "
+
orange
.
r
+
" | "
+
orange
.
g
+
" | "
+
orange
.
b
+
"\n"
);
out
.
println
(
yellow
);
out
.
println
(
purple
);
out
.
println
(
orange
);
}
//void main ()
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment