面向对象编程与过程编程 [英] Object Oriented Programming vs Procedural Programming

查看:91
本文介绍了面向对象编程与过程编程的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们可以使用过程编程来解决使用面向对象编程概念可以解决的任何问题吗?我的问题是,有些特殊问题只能使用OOP概念来解决.

Can we use Procedural Programming to solve any problem that can be solved using Object Oriented Programming Concepts? My problem is are there some particular problems which can only be solved using OOP concepts.

请帮助我理解这一点.

推荐答案

是.使用OOP可以解决的任何问题都可以使用过程编程来解决.最后,编译器只是将您的OOP代码转换为程序集.

Yes. Anything that can be solved using OOP can be solved using procedural programming. In the end the compiler just turns your OOP code into assembly, which is procedural.

一切都取决于计算机中CPU/RAM等的组合.由于您的计算机调整为完全,它可以解决任何其他语言或机器可以解决的任何问题也是图灵完成的.

It all comes down to what the combination of the CPU/RAM etc in your computer can do. Since your computer is Turing Complete it can solve any problem that be solved by any other language or machine that is also Turing Complete.

这篇关于面向对象编程与过程编程的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆