In C/C++, you can initialise a struct without giving values for any of the fields:
struct Point {
float x;
float y;
float z;
};
my_numbers = [0, 1, 2, 3, 4, 5] | |
odd_number_count = 0 | |
for number in my_numbers: | |
if number % 2: | |
odd_number_count += 1 | |
print(odd_number_count) |
> "This is a string" | |
"This is a string" : String | |
> 2.71828 | |
2.71828 : Float | |
> 123 | |
123 : number | |
> [1, 2, 3, 4, 5] |
doubleIt : number -> number | |
doubleIt n = n * 2 | |
import String | |
stringify : number -> String | |
stringify n = toString n | |
addX : String -> String | |
addX s = s ++ "X" |
import String | |
import Html | |
import List | |
type alias Person = { name : String | |
, access : List String } | |
type alias Location = String | |
ee1 = { name = "Ian Beal" |
def fit_heptad_register(crangles): | |
"""Attempts to fit a heptad repeat to a set of Crick angles. | |
Parameters | |
---------- | |
crangles: [float] | |
A list of average Crick angles for the coiled coil. | |
Returns | |
------- | |
fit_data: [(float, float, float)] | |
Sorted list of fits for each heptad position. |
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<script type="text/javascript" src="elm.js"></script> | |
</head> | |
<body></body> | |
<div id="main"></div> | |
<script type="text/javascript"> | |
var node = document.getElementById('main'); |