Homework on EVM

1. What does the EVM do?
The EVM - Ethereum Virtual Machine - assists nodes in reading smart contracts and then communicating the instructions for the CPU to operate. The EVM ensures that there is security for the node and there is no malicious code that will be dangerous to the CPU. It does this by encapsulating the contract and making sure it is safe when it translates it to the CPU. This is to protect the whole Ethereum network to make sure that nobody writes a smart contract that takes over the nodes and controls the computer’s CPUs, which could result in a massive disaster for the network as a collective, and each node running the contract. Essentially the EVM is crucial for network security and node safety.

2. What is the format of the instructions that the EVM can read?
Bytecode is the code format that the EVM can read. The instructions are most often written in the programming language called Solidity and then run through a compiler that translates it into Bytecode format that is then read by the EVM.

3. What is the relationship between the programming language Solidity and Bytecode?
Bytecode is the format that smart contract codes written in solidity are converted into when compiled. The EVM only reads Bytecode and it is a crucial language for the Ethereum network. Other languages such as Viper are now being used to construct smart contracts as well and they are also converted into Bytecode for the EVM.

4. Why can’t Bitcoin run the same type of complex programs like Ethereum can?
Bitcoin uses a programming language called Script that allows for small programs to be written on its blockchain for things such as multi-signature transactions. However, these programs are very elementary compared to Ethereum smart contracts. Script is not a Turing Complete programming language. Solidity on the other hand is a Turing Complete language and allows you to program anything you want. Solidity contains loops while Script does not, and this makes a big difference in the programs that can be created using these languages. Bitcoin actually decided to use Script instead for this reason, to reduce spam and makes the network less congested so it can serve its purpose as money. Ethereum is the alternative that provides fully programmable money. This is the major difference between the two blockchains.

5. What is a Turing Complete programming language?
A Turing Complete programming language lets you program anything you want and has the ability to run loops which are short pieces of code that can tell the computer to run a code multiple times over and over again. In a non-Turing language, you must write each instruction for every repeat in code, unlike loops that let you use only one code for multiple executions.

1 Like
  1. Reads & executes (using each node’s CPU) smart contracts.
  2. Bytecode
  3. Instructions written in Solidity are compiled to ByteCode so that EVM can read them.
  4. Ethereum has EVM and Solidity, and Bitcoin uses Script, witch is not a turing complete language.
  5. A programming language that can help you program anything.
1 Like
  1. What does the EVM do? The Ethereum Virtual Machine provides compute and memory to decentralized applications and smart contracts. The EVM runs on the decentralized hardware provided by node operators.
  2. What is the format of the instructions that the EVM can read? byte code
  3. What is the relationship between the programming language Solidity and Bytecode? Solidity is the programming language humans use to write smart contracts. These programs are compiled into byte code that is executable by the EVM
  4. Why can’t Bitcoin run the same type of complex programs like Ethereum can? The Bitcoin network does not have a programming language that is Turing complete.
  5. What is a Turing Complete programming language? A Turing complete programming language can be used to implement any possible algorithm.
1 Like

Excellent answers, It’s easy to understand. Please keep them like that :muscle:

Carlos Z.

1 Like
  1. The EVM is where smart contracts are interpreted and run.
  2. ByteCode
  3. Developers program in solidity, it is run through a compiler that converts it into Bytecode that the EVM then can read and execute.
  4. It does not allow for loops / is not Turing complete.
  5. This means that (in theory) anything can be made using a programming language that is “turing complete”.
1 Like

Homework: EVM

What does the EVM do?

- The EVM is a virtual machine that runs the smart contract for / by the node/cpu.
  1. What is the format of the instructions that the EVM can read?

    • The EVM reads/executes the contract instructions in Bytecode language.
  2. What is the relationship between the programming language Solidity and Bytecode?

    • Solidity is the language used to write the smart contract and instructions and is compiled into Bytecode for the EVM.
  3. Why can’t Bitcoin run the same type of complex programs like Ethereum can?

    • It was not designed for complex smart contracts. Only simple TX’s.
  4. What is a Turing Complete programming language?

    • For a program language to considered Turing Complete the language must be able to compute any problem in an ‘arbitrary’ amount of space.
1 Like
  1. EVM is ethereum virtual machine. It runs on top of ethereum throughout the network and is used to execute smart contracts. Once all steps of the contract are executed, the information and instructions are passed to the CPU.
  2. Bytecode
  3. Solidity is defined as a programming language used by ethereum to author smart contracts. The instructions of the contract are written in bytecode. EVM reads the code, then executes the instructions.
  4. Bitcoin programming language is not turing complete. It’s language is typically exclusive to immediate transactions.
  5. A programming language used to write theoretically any perceived program. As stated above, bitcoin does not employ a turing complete language. A turing complete lamguage such as solidity is used to author smart contracts with instruction written in bytecode, EVN then executes these demands. This complexity doesn’t exist in bitcoin, so a turing complete language is unnecessary.
1 Like
  1. Reads and executes smart contracts, provides security.
  2. It reads bytecode.
  3. Solidity compiles smart contract instructions down to bytecode so that the EVM can read the instructions.
  4. Bitcoin uses a language called script which is very primitive. It is not turing complete so its very limited in solving problems.
  5. A language with no limitations to what you can create from scratch.
1 Like

1_ the evm reads smart contracts and executes the code, protecting the cpu’s of all nodes on the network.

2_ Bytecode, input using solidity or viper.

3_ Solidity uses human understandable language into Byte, a language only robots and computers can understand.

4_ Bitcoin uses script, which is a not Turing complete, meaning it has a limit of operations.

4 or 5_ Turing complete means it can execute 1 or more commands x times and switch to other commands if conditions are met. This means you can program anything with less code.

1 Like
  1. What does the EVM do?
    It encapsulates the smart contract and reads the contracts script. Then it relays the script to the nodes cpu’s for confirmation.

  2. What is the format of the instructions that the EVM can read?
    Bytecode.

  3. What is the relationship between the programming language Solidity and Bytecode?
    Solidity is the base language which they use to code smart contracts and it gets put through a compiler so we get bytecode which EVM reads.

  4. Why can’t Bitcoin run the same type of complex programs like Ethereum can?

Bitcoin uses Script as a programming language and it is very basic and not turing complete programming language.

  1. What is a Turing Complete programming language?
    A Turing Complete programming language enables one to program anything they want and can run loops.
2 Likes

1 The Ethereum Virtual Machine is the global virtual computer whose state every participant on the Ethereum network stores and agrees on.

2 Bytecode

3 Bitecode is an intermediary between solidity and EVM. Solidity is translated into Bitecode and EVM can work with it.

4.The bitcoin network is a payment network and in not Turing complete. security, blockchain size

5 Programing language Turing complete, can run any program (irrespective of the language) that a Turing machine can run given enough time and memory. loops

1 Like
  1. Ethereum Virtual Machine runs on top of the excisting hardware and reads the smartcontract after which it gives intructions to the CPU.
  2. EVM Bytecode.
  3. The code for the smart contract is written in the programming language solidity and then compiled by a compiler to bytecode.
  4. Because it uses the programming language called script which gives it limited possibilities compared to solidity. Script is not turing complete.
  5. Solidity is turing complete and can program anything we want to.
1 Like
  1. The EVM reads the bytecode and transfers the instructions to the CPU.

  2. Bytecode

3.The bytecode is compiled of solidity.

  1. Bitcoin can’t run complex programs , because its programming language is Script. Script is a not turing complete language.

  2. It is a programming language that can be used to program any command. ( theoretically)

1 Like
  1. EVM works as a go between for smart contracts to the CPU
  2. Byte code
  3. Solidity complies into byte code
  4. The language SCRIPT is not TC (turing complete) meaning could end up with endless loops
  5. A programming language that can in theory complete any task given to it
1 Like
  1. The EVM interprets the code in the smart contract and executes it. It also acts as security, protecting the hardware from malicious code.
  2. The EVM can read byte code on the smart contract.
  3. Using a compiler the original solidity language is compiled into Bytecode
  4. Bitcoin is not Turing complete.
  5. A Turing complete programming language can create loops that allow for tasks be run multiple times taking into account any changes in the variables.
1 Like
  1. Ethereum Virtual Machine runs code of Smart Contracts. EVM is a kind of security firewall because it checks smart contracts for malicious code before compiling it to CPU instruction/code.

  2. EVM runs ByteCode.

  3. Solidity is a programming language. When you write code in Solidity you compile it and you have ByteCode.

  4. Bitcoin has a simple programming language called Script. Script has limited functions you are not able to program all you want. It is not Turing Complete.

  5. Solidity is Turing Complete programming language. You can program all you want. You have loops, conditions, etc.

1 Like

What does the EVM do?

EVM (Ethereum Virtual Machine) is software that runs on each node in the Ethereum Network. It ensures that smart contract software won’t take over the node’s computer and do damage.

What is the format of the instructions that the EVM can read?

The EVM reads bytecode. The source code compiler generates the bytecode.

What is the relationship between the programming language Solidity and Bytecode?

The compiler converts Solidity into bytecode.

Why can’t Bitcoin run the same type of complex programs like Ethereum can?

The Bitcoin programming language is not Turing complete. For example, it can not run loops which could overwhelm the node computer.

What is a Turing Complete programming language?

A Turing Complete language allows the programmer to create any kind of instruction. For example, a Turing Complete language allows the execution of loops.

1 Like
  1. What does the EVM do?
    The EVM will look at the instructions in the smart contract and will do the calculations and finally will tell the CPU what to do to finally reach the result.
  2. What is the format of the instructions that the EVM can read?
    bytecode
  3. What is the relationship between the programming language Solidity and Bytecode?
    Solidity is a programming language in which all instructions and logic are compiled with a special app called compiler and turned into bytecode
  4. Why can’t Bitcoin run the same type of complex programs like Ethereum can?
    Because Bitcoin’s language “Script” can not solve all problems that it might have to solve if you want to program an application, that’s why tey call it “Not Turing Complete”
  5. What is a Turing Complete programming language?
    It is a language that has the funcion of “loops” that allow programmers to run instructions an X number of times within the same program
1 Like
  1. EVM runs on top of the existing hardware of each node in the Ethereum network and reads and executes each smart contract.
  2. It will be written in Solidity but then compiled into EVM byte code.
  3. Solidity is the programming language sort of like Java Script that programmers use to get the language into byte code via a special application called a compiler.
  4. The scripting language in Bitcoin is not Turing complete and therefor cannot solve all problems if programming specific applications.
  5. Solidity is an example of a Turing Complete language meaning that you can program basically anything complex and consists of Loops.
1 Like
  1. The EVM runs smart contracts before the CPU which gives transparency and security something bc can’t do. 2. Byte code. 3. Solidity is compiled into Bytecode and runs on the EVM. 4. Bitcoin is not Turing complete (no loops) involved