茱莉亚分形_茱莉亚的NaN Constant

茱莉亚分形

Julia| NaN / Nan64常数 (Julia | NaN/Nan64 Constant)

Nan / Nan64 is a constant of the Float64 type in Julia programming language, it represents "not-a-number" value.

Nan / Nan64是Julia编程语言中Float64类型的常量,它表示“非数字”值。

Syntax:

句法:

    NaN
    NaN64

Example:

例:

In this example, we are taking two variables x and y and assigning them with NaN and NaN64. We are printing the values and types of x and y using println() function and typeof() function. We are also comparing the NaN and NaN64.

在此示例中,我们采用两个变量x和y ,并为其分配NaN和NaN64 。 我们正在使用println()函数typeof()函数打印x和y的值和类型。 我们还在比较NaN和NaN64 。

# Julia example of NaN and NaN64

x = NaN
y = NaN64

println("x: ", x)
println("y: ", y)

println("typeof(x): ", typeof(x))
println("typeof(y): ", typeof(y))

# checking whether NaN and NaN64 are same
println("NaN==NaN: ", NaN==NaN64)

Output

输出量

x: NaN
y: NaN
typeof(x): Float64
typeof(y): Float64
NaN==NaN: false

Reference: Julia constants

参考: Julia常数

翻译自: https://www.includehelp.com/julia/nan-constant.aspx

茱莉亚分形

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值