readurl.m
来自「matlab7.0从入门到精通(光盘内容)」· M 代码 · 共 19 行
M
19 行
function readURL(website)
%read website's data,if no input,read default homepage.
if nargin==0
website='http://www.sina.com.cn';
end
%create URL object
url=java.net.URL(website);
%create input stream
is=openStream(url);
isr=java.io.InputStreamReader(is);
br=java.io.BufferedReader(isr);
%read network page's data
for i=0:44
s=readLine(br);
end
readLine(br)
readLine(br)
readLine(br)
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?