ポーランド西部、ドイツ国境の街ジェロナグラ

ジェロナグラでの日本語教師生活日記、近郊の街、おいしい食べ物 ポーランドの文化 気がついたこと徒然なるままに。

Photon Robot (Chapter 10/Reunion-4)第10章は中国が舞台です

 

最後のChapter 10は「中国」が舞台です。

「Photon」は、中国語でも日本語でも「光子」の意味です。

「 a particle representing a quantum of light or other electromagnetic radiation.

A photon carries energy proportional to the radiation frequency but has zero rest mass.」

そこで、タコやカニやエビを売っている店の看板は「光子」となっているわけです。

最後のステージが中国となるのはポーランド人の東洋への憧れのようなものでしょうか。

f:id:takky0116:20210225114942p:plain

f:id:takky0116:20210225115025p:plain

f:id:takky0116:20210225115034p:plain

これが、あらかじめ与えられたProgramの一部です。

 

問題は、

1   Do you still  remember what we did in Lesson 1and 3

 2   your task will be create a program using knowlage

      from these two lessons .

 3   I should drive nonstop and chacking for a wall.

 4   if the wall is less than 40cm away from me 

      I should cange color to red

      and I start  looking around...

 5   if the wall is less than 80cm away from me

      I should cange color to yellow

      and I start  looking around...

 6    if I don't detect the walll, I should change my color   to green.

 7    Looking around means to turn clockwise and check

       if there is anything block my way  less than 40cm away     from me ...

 8    if there is, I should turn 180 degrees

       and check  if there is any obstacle less than 40 cm from   me there....

 9    if there is, I should turn left.

10   Once all these steps are completed

  I should start drive endlessly .The program should start   driving endlessly.

  The program should return to the beginning.

 

この問題は、なかなか解くことができず

この段階でギブアップ。

サポートデスクに救援をたのみました。

それが、下に掲載したプログラムです。

最後のNo9 「   if there is, I should turn left.」

この部分は、あまりプログラムをいじりすぎてすっかり忘れてしまった部分です。

 

f:id:takky0116:20210228190531p:plain


    

 

こんなアドバイスをいただきました 。でも残念ながらクリアーできません

Dzień dobry  :)

 

Don't worry, this stage is difficult for everyone!

I'll be happy to help you. ;)

 

1. According to the instruction if the

robot doesn't detect the wall,

he should change his color to green.

In your program he changes his color only

when the wall is more than 80 cm away from

him.

To correct this part of the program you should

remove the "If obstacle" block and leave only

"Change color".

 

2. Then the robot needs to look around.

At first he should turn clockwise - it means

that he has to turn left not 360 degrees.

 

3. After that he should check if there's any

obstacle blocking his way.

The robot has to check this condition only at

that one moment so there's no need to add

the "Infinity" loop here. 

 

4. If there's an obstacle he should turn 180

degrees and this part is correct.

Notice that after turning he should check

again if there's any obstacle less than 40 cm

away from him

and if there is, he should turn left. 

This part is missing in your program.

 

5. At the end the robot should start driving

endlessly and you did it well. :)

Let me know if the tips above helped! I look

forward to hearing back from you.

 

Best,

 

ほうぼう間違えていて相当修正が必要なようです。

そして、上のアドバイスを受けて改良したプログラムです。

一応、それらしい動きはするのですが、ターン180度 したところで止まってしまい、目の前に障害物を差し出すとまた動き出すという状態です。

 

そこで、再々のアドバイス依頼。

ポーランド語でDzień dobryと冒頭に挨拶したら「おはようございます」と返ってきました。

一応このシステムはドイツ語、英語、オランダ語、日本語、中国語他10か国語を選ぶことができます。

また、中国語は繁体字簡体字の2種類に分かれている親切さです。

 

f:id:takky0116:20210227173735p:plain

 

 

おはようございます  :)

Here are my tips for you:
1. Your program should start with the "Drive forward" block. The part with detecting obstacles and changing colors is correct. 


2. After turning right the robot should check if there's any obstacle blocking his way. 
When you use the "Repeat" block and the "If there's obstacle" block it means that the robot has to wait for an obstacle to go on.
According to the instructions, the robot has to check this condition only at that one moment so there's no need to add the "Repeat" block here you should remove it.
 
3. If there's an obstacle he should turn 180 degrees and this part is correct.
After that he should check again if there's any obstacle less than 40 cm away from him and if there is, he should turn left. Notice that he should check this condition after detecting an obstacle from point 2.
You should place the second "If there's obstacle" block inside the first "If there's obstacle" block.
That will cause the robot to check if there's a second obstacle on his way after detecting the first one.
 
I hope my tips are understandable. :) I will wait for the screenshot with the changes made!

このアドバイスを基に再々作成したのが下のプログラムです。

これで、クリアーできなかったので、再度照会したのですが

送ったら、これでparfectとこと。

でも、これでもクリアーできません。

プログラムはあっているということなのですが。

f:id:takky0116:20210227174337p:plain

 Your program is perfect! :)

After pressing the "start" button you should get a message

"Challenge complete! Tap [Stop] to finish". When you tap stop

you're going to clear this stage. :)

Let me know if you completed this challenge.

 

これでもまだクリアーできないとは不思議です。

流れはあっているとのこと???

ふと思いついて、「Green」と指示があるところを「Light Green」に替えてみました。そうしたら、見事にクリアーすることができました。

f:id:takky0116:20210227181124p:plain

完成版です