After F5 is clicked, the code e.Graphics.DrawRectangle(Pens.Red, 11, 18, 3, 2) creates in the windows form a (choices for this blank: (a) vertical; (b) horizontal) rectangle whose dimensions are: height= pixels and width= In the For-Next Loop, the 1st iteration for variable i draws a red rectangle whose upper left corner is located at Y= and X- For the following pixel color question, the choices are: Red: Green Blue: White: Mixed Colors. Please write the color name in the blanks. The pixel color at location (10,9) is The pixel color at location (11,11) is The pixel color at location (11,14) is The pixel color at location (11,20) is The pixel color at location (12,11) is The pixel color at location (13,13) is The pixel color at location (13,13) is The pixel color at location (14,11) is The total number of red-colored pixels is Number of iterations done for the code above is The final value of intX when debugging ends is

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter14: Introduction To Swing Components
Section: Chapter Questions
Problem 11RQ
icon
Related questions
Question
After F5 is clicked, the code e.Graphics.DrawRectangle(Pens.Red, 11, 18, 3, 2) creates in the windows form a
(choices for this blank: (a) vertical; (b) horizontal} rectangle whose dimensions are: height=
pixels and width=
In the For-Next Loop, the 1st iteration for variable i draws a red rectangle whose upper left corner is located at
Y=
and X=
For the following pixel color question, the choices are: Red: Green: Blue: White: Mixed Colors. Please write the
color name in the blanks.
The pixel color at location (10,9) is
The pixel color at location (11,11) is
The pixel color at location (11,14) is
The pixel color at location (11,20) is
The pixel color at location (12,11) is
The pixel color at location (13,13) is
The pixel color at location (13,13) is
The pixel color at location (14,11) is
The total number of red-colored pixels is
Number of iterations done for the code above is
The final value of intX when debugging ends is
Transcribed Image Text:After F5 is clicked, the code e.Graphics.DrawRectangle(Pens.Red, 11, 18, 3, 2) creates in the windows form a (choices for this blank: (a) vertical; (b) horizontal} rectangle whose dimensions are: height= pixels and width= In the For-Next Loop, the 1st iteration for variable i draws a red rectangle whose upper left corner is located at Y= and X= For the following pixel color question, the choices are: Red: Green: Blue: White: Mixed Colors. Please write the color name in the blanks. The pixel color at location (10,9) is The pixel color at location (11,11) is The pixel color at location (11,14) is The pixel color at location (11,20) is The pixel color at location (12,11) is The pixel color at location (13,13) is The pixel color at location (13,13) is The pixel color at location (14,11) is The total number of red-colored pixels is Number of iterations done for the code above is The final value of intX when debugging ends is
Given the codes below, provide the answers asked for.
e.Graphics.DrawRectangle(Pens.Red,
Private Sub Form1_Paint(ByVal sender As Object, ByVal e As System.Windows.Forms.PaintEventArgs) Handles Me.Paint
11, 18, 3, 2)
e.Graphics.DrawLine (Pens.Blue, 10, 8, 10, 20)
e.Graphics.DrawLine (Pens.Blue, 11, 9, 11, 22)
Dim intX As Integer = 1
Dim inty As Integer
For i As Integer = 1.5 To 11.5 Step 1.5.
If intX >= 0 Then
End Sub
inty 3* i + 2 * intX
Else
inty = i
End If
Next
e.Graphics.DrawRectangle(Pens.Green, inty, i, 3, 2)
e.Graphics.FillRectangle (Brushes.Red, intY + 1, i + 1, 1, 1)
intX = 1.5
e.Graphics.FillRectangle(Brushes.Green, 8, 14, 3, 2)
e.Graphics.FillRectangle(Brushes.Green, 11, 11, 3, 2)
Transcribed Image Text:Given the codes below, provide the answers asked for. e.Graphics.DrawRectangle(Pens.Red, Private Sub Form1_Paint(ByVal sender As Object, ByVal e As System.Windows.Forms.PaintEventArgs) Handles Me.Paint 11, 18, 3, 2) e.Graphics.DrawLine (Pens.Blue, 10, 8, 10, 20) e.Graphics.DrawLine (Pens.Blue, 11, 9, 11, 22) Dim intX As Integer = 1 Dim inty As Integer For i As Integer = 1.5 To 11.5 Step 1.5. If intX >= 0 Then End Sub inty 3* i + 2 * intX Else inty = i End If Next e.Graphics.DrawRectangle(Pens.Green, inty, i, 3, 2) e.Graphics.FillRectangle (Brushes.Red, intY + 1, i + 1, 1, 1) intX = 1.5 e.Graphics.FillRectangle(Brushes.Green, 8, 14, 3, 2) e.Graphics.FillRectangle(Brushes.Green, 11, 11, 3, 2)
Expert Solution
steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Methods of StringBuilder class
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
Programming Logic & Design Comprehensive
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage