首页 > 代码库 > different between method and function
different between method and function
<style>p.p1 { margin: 0.0px 0.0px 0.0px 0.0px; font: 15.0px Arial; color: #242729 }
p.p2 { margin: 0.0px 0.0px 0.0px 0.0px; font: 15.0px Arial; color: #242729; background-color: #ffffff }
span.s1 { background-color: #ffffff }
span.s2 { }</style>
A method is on an object.
A function is independent of an object.
For Java, there are only methods.
For C, there are only functions.
For C++ it would depend on whether or not you‘re in a class.
different between method and function
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。