BASH/C3/Arrays-and-functions/Khasi
From Script | Spoken-Tutorial
Revision as of 21:04, 4 June 2017 by Meboreen Mary (Talk | contribs)
Time | Narration |
00:01 | Paralok baieid, ngi pdiangsngewbha iaphi sha ka spoken tutorial halor ka “Arrays & functions”. |
00:07 | Ha kane ka jinghikai, ngin ia pule shaphang: |
00:11 | Ban pass ia ka “array” sha ka “function” |
00:14 | Ban pyndonkam ia ka “exit” statement ha ka “function” |
00:17 | Ban pyndonkam ia ka “return” statement ha ka “function” |
00:20 | Da ka jingiarap jong katto katne ki nuksa. |
00:24 | Ban bud ia kane ka jinghikai, phi dei ban don ia ka jingtip jong ka Shell Scripting. |
00:29 | Phi dei ban don ia ka jingtip jong ki “arrays” bad “if” statement” ha ka BASH. |
00:36 | Lada phim pat tip, na ka bynta ki jinghikai kiba iadei, sngewbha leit sha ka website kumba la pyni. http://www.spoken-tutorial.org |
00:43 | Na ka bynta kane ka jinghikai, nga pyndonkam da ka: |
00:46 | Ubuntu Linux 12.04 Operating System bad ka |
00:50 | GNU BASH version 4.2 |
00:54 | Sngewbha kynmaw, ba ka “GNU Bash” “version 4” lane kham shajrong la ai jingmut na ka bynta kane ka jinghikai. |
01:02 | To ngin ia pule shwa nyngkong kumno ban pass ia ka “array” sha ka “function” bad ka jingpyn donkam ia ki. |
01:09 | To ngan plie ia ka file function_(underscore)array dot sh. |
01:15 | Kane kadei ka shebang line. |
01:18 | Ka kyrteng jong ka function jong ngi kadei array_(underscore) display. |
01:22 | Open curly brace u plie ia ka “function” definition. |
01:27 | Ka jingpyndonkam ia u Dollar @(at-sign) lah batai ha ka jinghikai kaba hashwa ha kane ka series. |
01:34 | La pyndonkam ia u ban “print” ia baroh ki “argument” ba lah pass sha ka “function.” |
01:40 | Dollar @ (at sign) hapoh jong round brackets u buh ia ki “array elements” ha ki “array” variable. |
01:47 | “Dollar” opening curly brace “array” hapoh jong u square bracket @(At-sign) closing curly brace. |
01:55 | Kane ka lain jong u code ka pyni ia baroh ki “elements” jong ka “array.” |
02:00 | “Dollar” opening curly brace “array” hapoh jong ki square brackets one closing curly brace. |
02:08 | Kane ka lain jong u code ka pynpaw ia ka “element” ba ar jong ka “array”. |
02:14 | “operating systems” lah declare bad ki elements “Ubuntu”, “Fedora”, “Redhat” bad “Suse”. |
02:22 | Hangne, array “operating systems” lah pass sha ka function “array_display.” |
02:29 | Ka syntax ban pass ia ka “array” sha ka “function” kadei “function_name” space “dollar” opening curly brace “array_name” hapoh square brackets “@(At sign)” closing curly brace. |
02:45 | Phai biang sha ka program jong ngi. |
02:48 | Ha kajuh ka rukom, ka “colors” lah declare bad ki “elements” “White, green, red” bad “blue”. |
02:57 | Hangne, “array” “colors” lah pass sha ka “function” “array_display”. |
03:02 | Mynta to ngin “save” ia ka file bad leit sha ka “terminal”. |
03:07 | Type: chmod space plus x space function underscore array dot sh |
03:18 | Nion Enter.Type: dot slash function underscore array dot sh |
03:25 | Nion “Enter.” |
03:27 | Kumba ngi lah ban iohi, “array elements” jong ka “operating_systems” bad ka “colors” lah pyni. |
03:33 | Bad ka “array element” ba ar jong ka “operating_systems” bad “colors” ruh lah pyni. |
03:41 | Ha ka “Bash”, “ ‘exit’ “ bad “ ‘return’ “ statements ki ai ia ka “status code” jong ka “function” lane ka program. |
03:49 | Ka “return” statement kan pynphai ia ka “script” na ka jaka ba la khot ia ka. |
03:54 | “exit” statement kan pynkut ia baroh kawei ka “script” na ka jaka ba lah buh. |
04:01 | To ngin ia pule ia kine ki 2 tylli ki rukom ban “return” hapoh jong ka “function.” |
04:06 | To ngin plie ia ka file 'return_exit.sh'. |
04:12 | Kane kadei ka shebang line. |
04:14 | Ka kyrteng jong kane ka function kadei return_(Underscore)function . |
04:18 | Open curly brace ka plie ia ka “function” definiftion. |
04:22 | Kane ka “if” statement ka pynia nujor ia kine ki ar tylli ki “variables”. |
04:27 | Lada kine ar tylli ki variable ki ia ryngkat te ka “commands” hapoh ha “if” lah execute. |
04:33 | Kane ka “echo” statement ka pyni ia ka khubor: |
04:36 | "This is return function". |
04:39 | return 0 ka pynkynriah ia ka control na ka function sha ka main program bad ia ka status code 0(zero). |
04:47 | Kynmaw ba ka statements hadien ka “return” kan nym shah execute ha ka “function”. |
04:54 | 'fi' ka pynithuh ia ka jingkut jong ka 'if' statement. |
04:58 | Hangne ka kyrteng jong ka function kadei ka exit_(Underscore)function. |
05:02 | Ka “if” statement hangne, ka ia nujor ia ar tylli ki variables. |
05:06 | Lada ki ar tylli ki variables ki ia ryngkat te ka “command” ha ka “if” kan sa execute. |
05:14 | Kane ka “echo statement” ka pyni ia ka khubor "This is exit function" . |
05:19 | “exit 0” kan sa pynkut ia ka program. |
05:23 | 'fi' ka pynithuh ia ka jingkut jong ka 'if' statement. |
05:27 | Kane kadei ka function call bad ki arguments 3 bad 3. |
05:33 | Kane ka pyni ia ka khubor "We are in main program". |
05:38 | Kane kadei kawei pat ka function call' bad ki arguments 3 bad 3. |
05:44 | Kane ka echo statement ka pyni ia ka khubor "This line is not displayed". |
05:49 | Kynmaw ba ka “exit” kan pynkut ia ka program. |
05:53 | Kiei kiei kiba don hadien jong ka “exit” kin nym shah execute. |
05:58 | Save ia ka file bad leit sha ka terminal. |
06:00 | Type: chmod space plus x space return underscore exit dot sh |
06:09 | Nion Enter. |
06:12 | Type: dot slash return underscore exit dot sh |
06:18 | Nion Enter. |
06:20 | Ka “output” kan pyni ia ka khubor kumba la pyni hangne. |
06:24 | Mynta, to ngin pyrshang ban sngewthuh ia ka jingiaid jong ka program. |
06:27 | U “control” un don ha ka “main’ program kaba dei hi ka “script”. |
06:33 | U control u leit sha ka “return_function” namar jong ka “function call.” |
06:39 | Kumba ki ar tylli ki “variables” ki ia ryngkat, ka pyni ia ka khubor "This is return function". |
06:47 | Bad ka ia tyngkhuh ia u return 0. Bad ka control ka iaid na ka function sha ka statement hapoh jong ka function call, ha ka main program. |
06:59 | Nangta ka pyni ia ka khubor "We are in main program" . |
07:03 | Hadien kata, u “control” u leit sha ka “exit_function” namar jong ka “function call”. |
07:11 | Kumba ar tylli ki variables ki ia ryngkat, ka pyni ia ka khubor "This is exit function". |
07:19 | Nangta ka ia tyngkhuh ia u “exit 0”. Kane kan pynkut ia ka program. |
07:25 | Kano kano ka statement hadien jong ka “exit” kan nym shah execute. |
07:30 | Bad ruh, ka statement “This line is not displayed” kan nym shah execute. |
07:36 | Kyrmen ba kine ki jingiapher ki lah shai iaphi. |
07:39 | To ngin peit mynta ia ki jingtip kyllum. |
07:41 | Ha kane ka jinghikai, ngi lah pule kumno ban: |
07:44 | Ban pass ia ka “array” sha ka “function” |
07:47 | Ban pyndonkam ia ka “exit” statement ha ka “function” |
07:50 | Ban pyndonkam ia ka “return” statement ha ka “function” |
07:53 | Da ka jingiarap jong katto katne ki nuksa. |
07:56 | Kum ka kam iaphi- thoh ia ka program |
07:58 | Ha kaba ka function ka pyndap ia baroh ki elements ha ka array. Ka function kadei ban pyni ia ka jingkhein kyllum jong ki elements. |
08:07 | Pynlong 2 “function” “calls” bad ka “array elements” (1,2,3) bad (4,5,6). |
08:15 | Peit ia ka video kaba don ha ka link harum http://spoken-tutorial.org/What_is_a_Spoken_Tutorial |
08:19 | Ka batai kyllum ia ka Spoken Tutorial project. |
08:23 | Lada phim don ia ka bandwidth kaba biang, phi lah ban shu download bad peit ia ka hadien. |
08:28 | Ka kynhun jong ka Spoken Tutorial: |
08:30 | Ka pynlong ia ki workshops da kaba pyndonkam ia ki spoken tutorials. Ka ai certificates sha kito kiba pass ha ka online test. Na ka bynta ki jingtip ba bniah, sngewbha thoh sha ka contact@spoken-tutorial.org |
08:45 | “Spoken Tutorial” Project kadei shi bynta jong ka “Talk to a Teacher” project. |
08:49 | La kyrshan ia ka da ka National Mission on Education lyngba ka ICT, MHRD, Sorkar India. Kham bun ki jingtip halor kane ka mission kidon ha ka link ba la ai harum. http://spoken-tutorial.org/NMEICT-Intro |
09:04 | Ia kane ka script la noh synniang da ka FOSSEE bad ka kynhun jong ka Spoken-Toturial. |
09:10 | Ma nga i Meboreen na Shillong nga pynkut ia kane. Khublei shibun. |