{"text_format":"1","workbook":"xlsx","n_sheets":3,"sheets":["問題文＆解答","正答","読み込み&書き込みシート"],"not_rendered":{"charts":0,"images":1,"macros":1,"external_links":0,"defined_names":0,"comments":0,"pivot_tables":0},"unopened":[],"bounds":{"document_bytes":16777216,"sheet_cells":100000,"rows_first":2000,"rows_last":500,"rows_between":2000,"halvings":0,"cell_chars":16384,"cell_head_chars":4096},"cells_cut":0,"cells_raw":0,"read":"whole","date_system":"1900"}

{"sheet":"問題文＆解答","index":0,"n_rows":10,"n_cols":4,"rows_kept":10,"cut":false,"hidden":false,"merged":[]}
[]
[]
[]
[]
[null,"問題文",null,"解答方法"]
[null,"以下の要件を満たすVBAの\nプログラムを実装して下さい。",null,"解答プログラムは\n「開発」\n→「Visual Basic」\n→「Answer」\n内のSub answer()に記載して下さい。"]
[]
[null,"要件"]
[null,"シート「読み込み＆書き込みシート」の読み込みセルの値を取得し, \nその値に応じて以下のように「書き込みセル」に書き込む。\n読み込みセルの値:「あなたの出身地は？」→書き込みセルに書き込む値:「東京都」\n読み込みセルの値:「好きな食べ物は？」→書き込みセルに書き込む値:「寿司」\n読み込みセルの値:「あなたの職業は？」→書き込みセルに書き込む値:「エンジニア」\n（読み込みセルの値:空白→書き込みセルに書き込む値:空白）"]
[null,"実行完了時にはMsgBox関数で「実行完了」のメッセージを表示する。"]

{"sheet":"正答","index":1,"n_rows":7,"n_cols":2,"rows_kept":7,"cut":false,"hidden":false,"merged":[]}
[]
[]
[]
[]
[null,"正答プログラム例"]
[null,"Sub correctAnswerExample()\n    Dim readWriteSht As Worksheet\n    Dim writeCell As Range\n    Dim readValue As String\n    Dim writeValue As String\n    ' 読み込み＆書き込みシートを取得\n    Set readWriteSht = ThisWorkbook.Sheets(\"読み込み&書き込みシート\")\n    ' 読み込みセルの値を取得\n    readValue = readWriteSht.Cells(6, 2).Value\n    ' 書き込みセルの範囲を指定\n    Set writeCell = readWriteSht.Cells(6, 4)\n    ' 読み込み値に応じて書き込みセルに書き込む値を設定（読み込み値が空白の場合は, writeValueは初期値（空白）のまま）\n    If readValue = \"あなたの出身地は？\" Then\n        writeValue = \"東京都\"\n    ElseIf readValue = \"好きな食べ物は？\" Then\n        writeValue = \"寿司\"\n    ElseIf readValue = \"あなたの職業は？\" Then\n        writeValue = \"エンジニア\"\n    End If\n    ' 書き込みセルに値を書き込む\n    writeCell.Value = writeValue\n    ' 「実行完了」のメッセージを表示\n    Call MsgBox(\"実行完了\")\nEnd Sub"]
[null,"↑上のプログラムは\n「開発」\n→「Visual Basic」\n→「CorrectAnswerExample」\nに記載してあります。"]

{"sheet":"読み込み&書き込みシート","index":2,"n_rows":7,"n_cols":4,"rows_kept":7,"cut":false,"hidden":false,"merged":[]}
[]
[]
[]
[]
[null,"読み込みセル",null,"書き込みセル"]
[null,"あなたの出身地は？"]
[null,"↑読み込みセルの値を毎回, 変更して, 実行してみて下さい！"]