当前位置:网站首页>Scala IO reads binary files
Scala IO reads binary files
2022-06-24 23:38:00 【Jue Niu thunder plough hot blade】
import java.io.{
File, FileInputStream}
object D05_ Read binary {
def main(args: Array[String]): Unit = {
val file = new File("./data/4.png")
val fis = new FileInputStream(file)
// val buf = new Array[Byte](file.length().toInt) // Writing at work
val buf = new Array[Byte](888888)
val len = fis.read(buf)
println(" Number of valid bytes read :" + len)
println(" The length of the byte array :" + buf.length)
}
}
4.png
4.png Location 
边栏推荐
- Bubble sort
- 年薪百万,7年测试经验:守在一个还算不错的赛道,慢慢积累,等风来
- 22map introduction and API
- 7-7 digital triangle
- go 语言指针,值引用和指针引用
- Use of types, values, namespaces, combinations, etc. in typescript
- Leetcode topic [array] -39- combined sum
- Huawei machine learning service speech recognition function enables applications to paint "sound" and color
- R语言使用epiDisplay包的aggregate函数将数值变量基于因子变量拆分为不同的子集,计算每个子集的汇总统计信息、自定义FUN参数为多个统计量函数名称的列表计算多个统计量
- 明天就是PMP考试了(6月25日),这些大家都了解了吗?
猜你喜欢

Annual salary of millions, 7 years of testing experience: stay at a fairly good track, accumulate slowly, wait for the wind to come
![[JS] - [string - application] - learning notes](/img/dc/f35979b094f04c0ee13b3354c7741d.png)
[JS] - [string - application] - learning notes
![[basic knowledge] ~ half adder & full adder](/img/06/7f1ede65dca527c8630285b587a4ba.png)
[basic knowledge] ~ half adder & full adder
HMS core discovery Episode 13 live broadcast Preview - building the real world in mobile games
![[JS] - [linked list - application] - learning notes](/img/e1/76d2a347b05212de349322f43e0b3a.png)
[JS] - [linked list - application] - learning notes

How to use stm32subeide SWV function

Continuous soul torture from two MySQL indexes of interviewers

From client to server

Harmonyos accessing database instances (3) -- use ORM bee to test how good harmonyos is

js监听页面或元素scroll事件,滚动到底部或顶部
随机推荐
Selective sort method
7-7 solving mode problems
golang convert json string to map
R语言使用MatchIt包进行倾向性匹配分析、使用match.data函数构建匹配后的样本集合、对匹配后的样本的不同分组对应的目标变量的均值进行Welch双样本t检验分析、双独立样本t检验
抖音实战~发布短视频流程梳理
throttle-debounce. JS: a small anti shake throttling function library
Ningde times will increase RMB 45billion: Hillhouse subscribes RMB 3billion and Zeng Yuqun still controls 23% of the equity
(Smooth)ScrollToPosition doesn't work properly with RecyclerView
Helix distance of point
Modify stm32f030 clock source to internal crystal oscillator (HEI)
QT cannot be edited with UTF-8
Actipro WPF Controls 2022.1.2
File contains vulnerability issues
7-2 solving the stock buying problem
R language uses GLM function to build Poisson log linear regression model, processes three-dimensional contingency table data to build saturation model, uses summary function to obtain model summary s
Spark's wide dependence and narrow dependence yyds dry goods inventory
华为机器学习服务语音识别功能,让应用绘“声”绘色
HarmonyOS访问数据库实例(3)--用ORM Bee测下HarmonyOS到底有多牛
7-8 circular scheduling problem
今天睡眠质量记录79分