ここを参考にするか、Storyboardを使うかしてNavigationController(ルートビューはMasterViewController)を配置する。 MasterViewController メインのViewではUISearchControllerを設定して、SearchResultViewControllerとのリンクを行う。 import UIKit class MasterViewController: UITableViewController { //データを定義 let data: [String] = ["This is a test sentence", "Please add your sentence.", "I like Apple", "Do you like an apple?", "今日はいい天気ですね", "はい、いい 天気です", "私はApp