Difference between revisions of "Assessment 2010 Easy"

From Progzoo
Jump to: navigation, search
(Adygea)
(1 Chita)
 
(17 intermediate revisions by the same user not shown)
Line 26: Line 26:
 
}
 
}
 
</shell>
 
</shell>
==Adygea==
+
 
<question className='Raster' imgOut='flag.png' width='250' height='125'>
+
 
[[Image:flag_of_Adygea.png|frame|Flag of Adygea]]
+
==1 Chita==
*The flag is 250 by 125
+
<question className='Raster' imgOut='flag.png' width='200' height='136'>
*The green is 41,107,14
+
[[Image:flag_of_Chita.png|frame|Flag of Chita]]
*The yellow is 255,214,0
+
*The flag is 200 by 136
*Radius of each star is 8
 
*9 stars on the circumference of a circle centre (125,105) radius 90
 
*The 9 stars are take from a circle of 20 equally spaced stars
 
*The arrows are at an angle of 40 degrees.
 
 
<prog><![CDATA[
 
<prog><![CDATA[
 
static void drawFlag(Graphics2D g){
 
static void drawFlag(Graphics2D g){
   g.setColor(new Color(41,107,14));
+
   g.setColor(Color.green);
   g.fillRect(0,0,250,125);
+
   g.fillRect(0,0,200,68);
  g.setColor(new Color(255,214,0));
 
  int n = 20;
 
  double r = 90.0;
 
  for (int i=0;i<9;i++){
 
    double a = i*2*Math.PI/n+2*Math.PI/n;
 
    drawStar(g,125+r*Math.cos(a),105-r*Math.sin(a),8.0);
 
  }
 
  double gap = r*Math.sin(2*Math.PI/n);
 
  drawStar(g,125,105-90+gap,8.0);
 
  drawStar(g,125+gap,105-90+gap,8.0);
 
  drawStar(g,125-gap,105-90+gap,8.0);
 
  drawArrow(g,125,84,0.0);
 
  double ang = 2*Math.PI/9;
 
  drawArrow(g,125,84,-ang);
 
  drawArrow(g,125,84, ang);
 
 
}
 
}
static Polygon star = new Polygon(
+
]]></prog>
  new int[]{0,22,95,36,59,0,-59,-36,-95,-22},
+
<answer>
  new int[]{-100,-31,-31,12,81,38,81,12,-31,-31},10);
+
static void drawFlag(Graphics2D g){
 +
  g.setColor(Color.green);
 +
  g.fillRect(0,0,200,68);
 +
  g.setColor(Color.red);
 +
  g.fillRect(0,68,200,68);
 +
Polygon tri = new Polygon();
 +
  tri.addPoint(0,0);
 +
  tri.addPoint(0,136);
 +
  tri.addPoint(100,68);
 +
  g.setColor(Color.yellow);
 +
  g.fillPolygon(tri);
 +
}
 +
</answer>
 +
</question>
 +
Now try the next question.
  
static void drawStar(Graphics2D g,double x,double y,double r){
+
==2 Shakha==
  g.translate(x,y);
+
<question className='Raster' imgOut='flag.png' width='200' height='100'>
  g.scale(r/100.0,r/100.0);
+
[[Image:flag_of_Shakha.png|frame|Flag of Shakha]]
  g.fillPolygon(star);
+
*The flag is 200 by 100
  g.scale(100.0/r,100.0/r);
+
*The stripe blue is 68 high
  g.translate(-x,-y);
+
*The white stripe is 10 high
 +
*The red stripe is 10 high
 +
*The circle has radius 20
 +
<prog><![CDATA[
 +
static void drawFlag(Graphics2D g){
 
}
 
}
 +
]]></prog>
 +
</question>
 +
  
static void drawArrow(Graphics2D g,int x, int y,double a){
+
==3 Udmurtia==
  g.translate(x,y);
+
<question className='Raster' imgOut='flag.png' width='198' height='100'>
  g.rotate(a);
+
[[Image:flag_of_Udmurtia.png|frame|Flag of Udmurtia]]
  g.drawLine(0,-19,0,30);
+
*The flag is 198 by 100
  Polygon head = new Polygon(new int[]{0, 4,-4},new int[]{-30,-18,-18},3);
+
*The width of the cross is 56
  g.fillPolygon(head);
+
*The width of the arm of a cross is 18
  int t = 20;
+
<prog><![CDATA[
  Polygon tail = new Polygon(
+
static void drawFlag(Graphics2D g){
new int[]{0,  4,   4, 0,-4,-4},
+
}
new int[]{t,t+4,30+4,30,30+4,t+4},6);
+
]]></prog>
  g.fillPolygon(tail);
+
</question>
  g.rotate(-a);
+
 
  g.translate(-x,-y);
+
==4 Mordovia==
 +
<question className='Raster' imgOut='flag.png' width='200' height='100'>
 +
[[Image:flag_of_Mordovia.png|frame|Flag of Mordovia]]
 +
*The flag is 200 by 100
 +
*The red is 160,0,0
 +
*The blue is 0,0,128
 +
*Each chevron is 4 from the centre
 +
*Each chevron has width 14
 +
*Each chevron has longest side 10
 +
<prog><![CDATA[
 +
static void drawFlag(Graphics2D g){
 +
}
 +
]]></prog>
 +
</question>
 +
 
 +
==5 Kurgan==
 +
<question className='Raster' imgOut='flag.png' width='200' height='134'>
 +
[[Image:flag_of_Kurgan.png|frame|Flag of Kurgan]]
 +
*The flag is 200 by 134
 +
*The green is 4,164,84
 +
*The leftmost point of the mountain is at 23,44
 +
*The base of one mountain is 44
 +
<prog><![CDATA[
 +
static void drawFlag(Graphics2D g){
 
}
 
}
 
]]></prog>
 
]]></prog>
 
</question>
 
</question>
 +
{{Assessment 2010}}

Latest revision as of 10:06, 16 June 2011

Flags of regions of Russia


1 Chita

Flag of Chita
  • The flag is 200 by 136


[Font] [Default] [Show] [Resize] [History] [Profile]

Now try the next question.

2 Shakha

Flag of Shakha
  • The flag is 200 by 100
  • The stripe blue is 68 high
  • The white stripe is 10 high
  • The red stripe is 10 high
  • The circle has radius 20


[Font] [Default] [Show] [Resize] [History] [Profile]


3 Udmurtia

Flag of Udmurtia
  • The flag is 198 by 100
  • The width of the cross is 56
  • The width of the arm of a cross is 18


[Font] [Default] [Show] [Resize] [History] [Profile]

4 Mordovia

Flag of Mordovia
  • The flag is 200 by 100
  • The red is 160,0,0
  • The blue is 0,0,128
  • Each chevron is 4 from the centre
  • Each chevron has width 14
  • Each chevron has longest side 10


[Font] [Default] [Show] [Resize] [History] [Profile]

5 Kurgan

Flag of Kurgan
  • The flag is 200 by 134
  • The green is 4,164,84
  • The leftmost point of the mountain is at 23,44
  • The base of one mountain is 44


[Font] [Default] [Show] [Resize] [History] [Profile]