1 SCREEN 1: CLS : KEY OFF
2 LINE (0, 0)-(311, 199), 2, B
3  LOCATE 4, 4: PRINT "    Определить напряженность и "
4  LOCATE 8, 4: PRINT "   потенциал электрического поля "
5  LOCATE 12, 4: PRINT "    точечного заряда q на  "
6 LOCATE 16, 4: PRINT "     расстоянии r от него   "
7 IF INKEY$ = "" THEN 7
10 CLS : SCREEN 1
20 LOCATE 3, 4: PRINT "          "
30 LOCATE 1, 2: PRINT "Введите величину заряда q,нКл": Q$ = "": LOCATE 3, 2: INPUT "q=", Q$: IF Q$ = "" THEN BEEP: GOTO 20:  ELSE Q = VAL(Q$)
40 LOCATE 5, 4: PRINT "          "
50 LOCATE 1, 2: PRINT "Введите расстояние до заряда r,м  ": R$ = "": LOCATE 5, 2: INPUT "r=", R$: IF R$ = "" THEN BEEP: GOTO 40:  ELSE R = VAL(R$)
55 IF R <= 0 THEN BEEP: GOTO 40
60 K = 9
70 E = K * Q / R ^ 2: F = K * Q / R
80 LOCATE 1, 2: PRINT "                                   "
90 LOCATE 1, 1: PRINT "Дано:": LOCATE 1, 15: PRINT "Решение:"
100 LOCATE 5, 5: PRINT "    ": LOCATE 3, 5: PRINT "    "
110 LOCATE 3, 1: PRINT "q="; Q; "нКл": LOCATE 5, 1: PRINT "r="; R; "м"
120 LOCATE 9, 1: PRINT "E - ?": LOCATE 7, 1: PRINT "ф - ?"
130 LOCATE 3, 15: PRINT "       q"
140 LOCATE 4, 15: PRINT "E = k─────"
150 LOCATE 5, 15: PRINT "      r¤"
160 LOCATE 7, 15: PRINT "      q"
170 LOCATE 8, 15: PRINT "Ф = k────"
180 LOCATE 9, 15: PRINT "      r"
190 LINE (80, 0)-(80, 100): LINE (80, 45)-(0, 45)
200 LOCATE 19, 2: PRINT "ОТВЕТ:"
205 E = INT(E * 100) / 100: F = INT(F * 100) / 100
210 LOCATE 19, 10: PRINT "E ="; E; "B/m": LOCATE 21, 10: PRINT "ф ="; F; "B"
220 LOCATE 23, 30: PRINT "ESC - Выход"
230 W$ = INKEY$: IF W$ = "" THEN 230
240 IF W$ = CHR$(27) THEN RUN "11111"
250 GOTO 10

