Use of @ in matlab code

2 views (last 30 days)
Rohit Singh
Rohit Singh on 19 Jun 2020
Commented: Stephen23 on 19 Jun 2020
What is the use of @ in given equation :
sqr=@(n) n.^2;
x=sqr(9)

Answers (1)

KSSV
KSSV on 19 Jun 2020
Edited: KSSV on 19 Jun 2020
@ does not have any value...it is a way to reperesent anonymous functions. Read about anonymous functions in matlab.

Categories

Find more on Mathematics in Help Center and File Exchange

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!