Interview Question with Answer
What are the difference between Ruby and PHP?
Difference between Ruby and PHP
Both Ruby and PHP languages are widely used. The websites of such well-known companies as Twitter, Hulu and Groupon are developed on Ruby. PHP is a language of Udemy, Wikipedia, and Facebook.
Difference between Ruby and PHP |
1. Ruby syntax is easy-to-comprehend, while PHP code may cause problems because of its syntax nature and standard library.
2. Statement terminator.
In Ruby, it is a newline character, in PHP – semicolon. For PHP, there is no secondary statement separator, while for Ruby it is a semicolon.
3. In PHP, blocks of code are ended with curly brackets, in Ruby – with the word ‘end’.
4. Integer data types. Ruby – no support, PHP supports 32-bit and 64-bit ones.
5. Frameworks.
Ruby – Cramping, Cramp, Ruby on Rails, Grape, Fiasco, Cuba. PHP – CakePHP, Codelgniter, Symfony, etc.
Yes it’s a very good blog, I gain so much knowledge thanks.
ReplyDeleteBrowse this site