设为首页收藏本站

最大的系统仿真与系统优化公益交流社区

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5258|回复: 2

[求助] 好困惑啊,帮帮忙?

[复制链接]
发表于 2010-1-27 11:16:30 | 显示全部楼层 |阅读模式
我在试着编程,很简单的取随机数,可就这样也不对,我不知道哪里错了,编译时没问题,而且在Eclipse环境下运行JSimpleBug的例程也没出错,可为什么我这个简单的试验程序却出错了呢?帮帮忙吧。在Eclipse环境下。
5 @, [4 b  h# b* himport swarm.Globals;
% x% c$ q# @! G
9 x$ w3 M) S; \/ r  }6 s: n) bpublic class test {
' E6 o3 c' L- x/ p# `/ d2 | /**
2 [/ i. j/ y* x' T. ]  * @param args2 r; e, K- Q: G, d4 g
  */" q3 O# R8 G. z9 @6 w2 y8 B
public static void main(String[] args) {
, q/ S: P/ O, ^3 I, T    , c* o1 q* t" i
     int y=(int)(10*Math.random());
7 K9 m$ \- c! \$ t7 g     System.out.println("result is "+y);% ~* N9 G/ N: @. V, P

; R: w: j4 M+ @( i) b# ^) `     double z=Globals.env.uniformDblRand.getDoubleWithMin$withMax(0.0, 1.0);3 P. K% p6 q6 \% o# z1 R9 J
  System.out.print(z+" re");
9 @6 k1 x- O$ q7 f6 q9 e" u& L  }+ o. K( B: q% ?& A1 u6 W1 t
}
+ n( t$ k' f& K6 l0 d8 ?
4 X) i9 L5 y4 p0 g结果是:0 c. Q( ]/ _% R/ h
result is 27 K% \7 U  S) G" o
#( d4 G, k  ]9 T% P2 k( I, C4 {4 }4 [4 m$ s
# An unexpected error has been detected by Java Runtime Environment:& L6 s) Z  r4 R
#) f0 M2 q8 w8 ^: ?5 H$ R: n
#  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x100b8305, pid=1064, tid=1068. O0 E' ]2 G5 y$ f
#
. m% F" X  D3 A# Java VM: Java HotSpot(TM) Client VM (1.6.0_01-b06 mixed mode, sharing)) C9 b. A. o9 O6 S" e; ~1 ?% D
# Problematic frame:
. s0 N; L) c1 A4 V1 b# C  [javaswarm.dll+0xb8305]8 ~8 D+ w$ A( U8 @7 T: V
#1 r* N, p: R* }9 {, G6 y# _  y
# An error report file with more information is saved as hs_err_pid1064.log
 楼主| 发表于 2010-2-1 11:07:41 | 显示全部楼层
怎么没有人帮我啊?我很急啊?版主帮帮吧
 楼主| 发表于 2010-2-1 11:11:40 | 显示全部楼层
看来这地方好久都没有人来了?
您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|Archiver|手机版|SimulWay 道于仿真   

GMT+8, 2026-2-7 08:28 , Processed in 0.017023 second(s), 14 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表