Eclipse中使用printf报错 提示参数类型不对 已解决The method printf(String, Object[]) in the type PrintStream is not ap
2016-08-17 19:26
976 查看
Eclipse中 JAVA默认的兼容版本为1.4, 改为1.5及以上版本就行。 项目 》属性》Java complier》complier compliance lever:1.5
System.out.printf("%f",d);//"f"表示格式化输出浮点数。
就正常了。
1.4版本 中 printf参数类型不一样,所以报错。
The method printf(String, Object[]) in the type PrintStream is not applicable for the arguments (String, int)
System.out.printf("%f",d);//"f"表示格式化输出浮点数。
就正常了。
1.4版本 中 printf参数类型不一样,所以报错。
The method printf(String, Object[]) in the type PrintStream is not applicable for the arguments (String, int)
相关文章推荐
- he method setAttribute(String,object)in the type HttpSession is not appl
- The method setItems(String) in the type ForTokensTag is not applicable for the arguments (Object)
- jsp The method getServletContext() is undefined for the type in eclipse解决方法
- jsp The method getServletContext() is undefined for the type in eclipse解决方法
- The method list(String, Object[]) is ambiguous for the type BaseHibernateDao<M,PK>错误解决方法
- The method replace(int, Fragment, String) in the type FragmentTransaction is not applicable for the arguments (int, SettingFragment, String)
- The method replace(int, Fragment) in the type FragmentTransaction is not app 解决方法
- 解决-The method setOnClickListener(View.OnClickListener) in the type View is not 错误
- Access restriction: The method typeNameToClass(String) from the type ObjectHandler is not accessible due to restriction on required library
- 在eclipse中如何使用RecyclerView解决The hierarchy of the type LiveCommentViewHolder is inconsistent
- 解决-The method setOnClickListener(View.OnClickListener) in the type View is not 错误
- The method replace(int, Fragment, String) in the type FragmentTransaction is not applicable...
- Error:The method setInputPaths(JobConf, String) in the type FileInputFormat is not
- The method setValue(String) in the type ParamTag is not applicable for the arguments (long)
- 提示错误:The method replace in the type.. is not applicable for the argument......
- The method replace(int, Fragment, String) in the type FragmentTransaction is not applicable for the
- c:forTokens 报错 The method setItems(String) in the type ForTokensTag is not applicable for the argume
- (转)eclipse 报错 :The method list(String, Object[]) is ambiguous for the type BaseHibernateDao
- The method sendKeys(CharSequence[]) in the type WebElement is not applicable for the arguments (String)
- The method setClass(Context, Class<?>) in the type Intent is not applicable for the arguments (GameV