mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Merge pull request #5091 from ethereum/readme-helloworld
Fix the HelloWorld example in the readme
This commit is contained in:
commit
d72498b3d2
@ -29,8 +29,10 @@ Instructions about how to build and install the Solidity compiler can be found i
|
|||||||
A "Hello World" program in Solidity is of even less use than in other languages, but still:
|
A "Hello World" program in Solidity is of even less use than in other languages, but still:
|
||||||
|
|
||||||
```
|
```
|
||||||
|
pragma solidity ^0.4.16;
|
||||||
|
|
||||||
contract HelloWorld {
|
contract HelloWorld {
|
||||||
function f() pure returns (string memory) {
|
function helloWorld() external pure returns (string memory) {
|
||||||
return "Hello, World!";
|
return "Hello, World!";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user