Language
No data
Notification
No notifications
391 Word
、変数iに探索開始位置(添字)の設定
, Hensū i ni tansaku kaishi ichi (soeji) no settei
, Set the search start position (index) to variable i
·繰り返しの終了条件は、引き出しをすべて見終わった、または、探し物が見つかったか
· Kurikaeshi no shūryō jōken wa, hikidashi o subete mi owatta, matawa, sagashi mono ga mitsukatta ka
The end condition for the loop is when all drawers have been searched or the item being searched for has been found.
·終了条件に当てはまらない間、変数iを+1して次の引き出しの場所を設定する
· Shūryō jōken ni atehamaranai ma, hensū i o + 1 shite tsugi no hikidashi no basho o settei suru
While the termination condition is not met, increment the variable i by 1 to set the location of the next withdrawal.
ことになる。いうことは探し物が見つかった数がn以下で止っいるとたことな。上の繰り返しで変あれば配には探し物はなかが配列の大きさnを超えたので··上の繰り返しで変数i値
Koto ni naru. Iu koto wa sagashi mono ga mitsukatta-sū ga n ika de toma~tsuiru tota kotona. Ue no kurikaeshi de hen areba hai ni wa sagashi mono wa naka ga hairetsu no ōki-sa n o koetanode··-jō no kurikaeshi de hensū i-chi
This means that the number of times the searched item was found is less than n. If there is a change in the above iteration, the searched item has exceeded the size of the array n, so the value of variable i in the above iteration
2分探索(バイナリサーチ
2-Bu tansaku (bainarisāchi
Binary search
探索の対村象となる配列が、あかじめ[②]に並でいるときに用いられる。常に配列の築索範囲の中央のデータと比較し、比較したデータよりも前半部分または後半部分を切り捨て、探索する範囲を徐々に狭めていく方法
Tansaku no tai-mura zō to naru hairetsu ga, akaji me [②] ni nami de iru toki ni mochii rareru. Tsuneni hairetsu no chiku saku hani no chūō no dēta to hikaku shi, hikaku shita dēta yori mo zenhan bubun matawa kōhan bubun o kirisute, tansaku suru hani o jojoni sebamete iku hōhō
This method is used when the target array for the search is already aligned [②]. It always compares the data in the center of the search range of the array, discards the first or second half of the compared data, and gradually narrows the search range.
最初はL=1,H=7M=(L+H)+2=(1+7)+2=4(端数が出る場合は、小数探索範囲の上,下限を示す変数をそれL、Hとし,中央の値Mを求める。点以下切り捨て)である。
Saisho wa L = 1, H = 7 M = (L + H) + 2 = (1 + 7) + 2 = 4 (hasū ga deru baai wa, shōsū tansaku hani no ue, kagen o shimesu hensū o sore L, H to shi, chūō no atai M o motomeru.-Ten ika kirisute)dearu.
Initially, L = 1, H = 7 and M = (L + H) + 2 = (1 + 7) + 2 = 4 (if a fractional part occurs, let the variables L and H indicate the upper and lower limits of the decimal search range, and find the middle value M. Truncate to the nearest point).
(2)配T(4)とXを比較する。51<77なので、Lを(L=M+1)移動して、前半部分を切り捨てる。3)残った範囲で、LとHからMを求める。1
(2 ) Hai T (4 ) to X o hikaku suru. 51 < 77Nanode, L o (L = M + 1) idō shite, zenhan bubun o kirisuteru. 3) Nokotta hani de, L to H kara M o motomeru. 1
(2) Compare the distribution T(4) with X. Since 51<77, move L (L=M+1) and truncate the first half. 3) Using the remaining range, find M from L and H. 1
後半部分を切④配列T(6)とXを比較する。89>77なので,Hを(H=M-1)移動して、り捨てる。⑤)残った範囲でしとHからMを求める。(の以下,T(M)=Xか,L>Hになるまで,④と⑤を繰り返す。
Kōhan bubun o setsu ④ hairetsu T (6 ) to X o hikaku suru. 89 > 77Nanode, H o (H = M - 1) idō shite,ri suteru.⑤) Nokotta hanideshi to H kara M o motomeru. (No ika, T (M ) = X ka, L > H ni naru made,④ to ⑤ o kurikaesu.
Cut off the latter half. ④Compare array T(6) with X. Since 89>77, move H (H=M-1) and discard it. ⑤) Find M from H in the remaining range. (Repeat steps ④ and ⑤ until T(M)=X or L>H.
例えば、辞書で単語を探す想像をしてみよう!辞書はアルファベット順やあいうえお順になっているね。最初に辞書の真ん中を開いて、見つけたい単語がそのページより前半か後半か判断して探すイメージだよ!2分探索法は、1回の探索で探索範囲を半分にすることができるんだ。従って、配列のデータが2倍になっても探索回数は1回しか増えないよ。
Tatoeba, jisho de tango o sagasu sōzō o shite miyou! Jisho wa arufabetto jun ya aiueojun ni natte iru ne. Saisho ni jisho no mannaka o aite, mitsuketai tango ga sono pēji yori zenhan ka kōhan ka handan shite sagasu imējida yo! 2-Bu tansaku-hō wa, 1-kai no tansaku de tansaku hani o hanbun ni suru koto ga dekiru nda. Shitagatte, hairetsu no dēta ga 2-bai ni natte mo tansaku kaisū wa 1-kai shika fuenai yo.
For example, imagine searching for a word in a dictionary! Dictionaries are arranged in alphabetical or alphabetical order. First, open the dictionary to the middle, and then determine whether the word you want to find is in the first or second half of that page. The binary search method can halve the search range in one search. Therefore, even if the data in the array doubles, the number of searches only increases by one.
の属性、項目、アトリビュート
No zokusei, kōmoku, atoribyūto
Attributes, items, and attributes of
【1】データベースの設計
[1 ] Dētabēsu no sekkei
[1] Database design
①実体
① Jittai
① Reality
キーや制約条件の定義
Kī ya seiyaku jōken no teigi
Defining keys and constraints
3一意性制約
3 Ichiiseiseiyaku
3. Uniqueness Constraints
正規化
せいきか
normalization (e.g. in floating-point representation system), normalisation, standardization, standardisation regularization
①繰り返し項目を独立
① Kurikaeshi kōmoku o dokuritsu
① Separate repeated items
③推移的関数従属
③ Suii-teki kansū jūzoku
③Transitive functional dependency
②部分関数従属
② Bubunkansū jūzoku
②Partial functional dependency
関係演算
かんけーえんざん
relational operation
(②射影
(② Shaei
(② Projection
③結合
③ Ketsugō
③Connection
端
はした はし はじ はな たん つま
edge, tip, end gable wall gable
実体
じったい
substance, entity, object entity
)関連
) Kanren
)connection