Toshkent arxitektura-qurilish universiteti


Asosiy qism : Menga beriligan vazifa 1-Dastur


Download 111.82 Kb.
bet2/2
Sana17.06.2023
Hajmi111.82 Kb.
#1544800
1   2
Bog'liq
21-Variant

Asosiy qism :
Menga beriligan vazifa
1-Dastur:

2-Dastur:

3-Dastur:

Misol sifatida namuna
1 misolning dasturi
Dastur ishlanishi va Natija:


2 misolning dasturi
Dastur ishlanishi va Natija:

Bu yerda x nomalumga son berish orqali tarmoqlanuvchi algoritm asosida ishlovchi dasturni ishlash kerak edi. Berilgan son 1 yani 0 dan katta bo’lgani uchun ikkinchi qatordagi formula asosida ishlandi va javobi ekranga chiqarildi



3 misolning dasturi (a)
Dastur ishlanishi va Natija:

Bu yerda x soni toki 1 bo’lmagunicha 0.2 ga qo’shib borilib uning javobini har safar ekranga chiqarish ko’rsatib berilgan


3 misolning dasturi (b)
Dastur ishlanishi va Natija:

Bu yerda k nomalumga 0 berib o’tdik hamda m ga har safar 1 dan 7 gacha sonlar kiritilib hisoblanganda yangi son chiqib keldi va engi so’ngida ushbu chiqqan sonlarni barchasi yig’indisi hisoblandi.




XULOSA


clc

Clears command window.

clear

Removes variables from memory.

exist

Checks for existence of file or variable.

global

Declares variables to be global.

help

Searches for a help topic.

lookfor

Searches help entries for a keyword.

quit

Stops MATLAB.

who

Lists current variables.

whos

Lists current variables (long display).
cd

Changes current directory.

date

Displays current date.

delete

Deletes a file.

diary

Switches on/off diary file recording.

dir

Lists all files in current directory.

load

Loads workspace variables from a file.

path

Displays search path.

pwd

Displays current directory.

save

Saves workspace variables in a file.

type

Displays contents of a file.

what

Lists all MATLAB files in the current directory.

wklread

Reads .wk1 spreadsheet file.

disp

Displays contents of an array or string.

fscanf

Read formatted data from a file.

format

Controls screen-display format.

fprintf

Performs formatted writes to screen or file.

input

Displays prompts and waits for input.



Adabiyotlar
1.Wikipedia.org
2.Mathworks.com


Download 111.82 Kb.

Do'stlaringiz bilan baham:
1   2




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling