diff --git a/gitlab-pages/docs/language-basics/cheat-sheet.md b/gitlab-pages/docs/language-basics/cheat-sheet.md
index 1e0e7aaef..6f46a6b3f 100644
--- a/gitlab-pages/docs/language-basics/cheat-sheet.md
+++ b/gitlab-pages/docs/language-basics/cheat-sheet.md
@@ -2,6 +2,8 @@
id: cheat-sheet
title: Cheat Sheet
---
+
+
@@ -32,6 +34,9 @@ title: Cheat Sheet
|Variant *(pattern)* matching|
const a: action = Increment(5);
case a of
| Increment n -> n + 1
| Decrement n -> n - 1
end
|
|Records|
type person is record
age: int ;
name: string ;
end
const john : person = record
age = 18;
name = "John Doe";
end
const name: string = john.name;
|
|Maps|
type prices is map(nat, tez);
const prices : prices = map
10n -> 60mtz;
50n -> 30mtz;
100n -> 10mtz;
end
const price: option(tez) = prices[50n];
|
+|Contracts & Accounts|
const destinationAddress : address = "tz1...";
const contract : contract(unit) = get_contract(destinationAddress);
|
+|Transactions|
const payment : operation = transaction(unit, amount, receiver);
|
+
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/gitlab-pages/docs/tutorials/get-started/tezos-taco-shop-payout.ligo b/gitlab-pages/docs/tutorials/get-started/tezos-taco-shop-payout.ligo
new file mode 100644
index 000000000..5623eaf3f
--- /dev/null
+++ b/gitlab-pages/docs/tutorials/get-started/tezos-taco-shop-payout.ligo
@@ -0,0 +1,37 @@
+type taco_supply is record
+ current_stock : nat;
+ max_price : tez;
+end
+type taco_shop_storage is map(nat, taco_supply);
+
+const ownerAddress: address = "tz1TGu6TN5GSez2ndXXeDX6LgUDvLzPLqgYV";
+const donationAddress: address = "tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx";
+
+function buy_taco (const taco_kind_index: nat ; var taco_shop_storage : taco_shop_storage) : (list(operation) * taco_shop_storage) is
+ begin
+ // Retrieve the taco_kind from the contract's storage
+ const taco_kind : taco_supply = get_force(taco_kind_index, taco_shop_storage);
+
+ const current_purchase_price : tez = taco_kind.max_price / taco_kind.current_stock;
+
+ if amount =/= current_purchase_price then
+ // we won't sell tacos if the amount isn't correct
+ fail("Sorry, the taco you're trying to purchase has a different price");
+ else
+ // Decrease the stock by 1n, because we've just sold one
+ taco_kind.current_stock := abs(taco_kind.current_stock - 1n);
+
+ // Update the storage with the refreshed taco_kind
+ taco_shop_storage[taco_kind_index] := taco_kind;
+
+ const receiver: contract(unit) = get_contract(ownerAddress);
+ const donationReceiver: contract(unit) = get_contract(donationAddress);
+
+ const donationAmount: tez = amount / 10n;
+
+ const operations : list(operation) = list
+ transaction(unit, amount - donationAmount, receiver);
+ transaction(unit, donationAmount, donationReceiver);
+ end;
+
+ end with (operations, taco_shop_storage)
\ No newline at end of file
diff --git a/gitlab-pages/docs/tutorials/get-started/tezos-taco-shop-payout.md b/gitlab-pages/docs/tutorials/get-started/tezos-taco-shop-payout.md
new file mode 100644
index 000000000..f22f59452
--- /dev/null
+++ b/gitlab-pages/docs/tutorials/get-started/tezos-taco-shop-payout.md
@@ -0,0 +1,180 @@
+---
+id: tezos-taco-shop-payout
+title: Paying out profits from the Taco Shop
+---
+
+In the [previous tutorial](tutorials/get-started/tezos-taco-shop-smart-contract.md) we've learned how to setup & interact with the LIGO CLI. Followed by implementation of a simple Taco Shop smart contract for our entepreneur Pedro. In this tutorial we'll make sure Pedro has access to tokens that people have spent at his shop when buying tacos.
+
+
+