---
# System prepended metadata

title: Programming II Lab 7 Task

---

## Programming II Lab 7 Task
In this task, you should create a program that takes a binary file (.bin), which then search for JPG images and extract them, the idea here is to implement a simple small file restoration program, the program itself will be a command-line utility.

A JPG file will always start with the two bytes `0xFF 0xD8` and end with `0xFF 0xD9`.

**Note:** Download [file.bin from here](https://drive.google.com/file/d/1RaRqLO5wqrWdXApGhkyU4rNhNh_K0R06/view?usp=sharing)

**Bouns:** There is a PNG picture in the file, extract it to get a bouns.

#### Expected output:

<center>

![Folder before running the program](https://i.imgur.com/rCn6Oih.png =600x)
Figure 1: Folder before running the program
</center>
---
<center>

![Running the program](https://i.imgur.com/fct8R5o.png =600x)

Figure 2: Running the program
</center>
---
<center>

![Folder after running the program](https://i.imgur.com/eurZbMo.png =600x)

Figure 3: Folder after running the program
</center>

---

<center>

### End of Lab 7 Task
</center>


<div style="display:none">

# Programming II Lab 7 Task
</div>