---
# System prepended metadata

title: Assignment 1 Questions

---

0. Edit this page to add questions. Ensure you number your question correctly.

1. Can I use ipynb notebooks?

2. Is it necessary to initialize the repo as a uv project? Can't we just use the installed python interpreter to test our solutions?

3. in the first question does the directory contain only files or sub directories+files?

4. Can we use big calculator in part A qn2? Bash is unable to handle 128 bit integers.

5. should we also backup empty directories in q1?

6. What is the correct format for backup.log out of the 3 below?
```
[2026-02-02 18:37:27] file1 - REASON NEW
[2026-02-02 18:37:30] file2 - REASON MODIFIED
```
```
[2026-02-02 18:37:27] file1 - REASON (NEW)
[2026-02-02 18:37:30] file2 - REASON (MODIFIED)
```
```
[2026-02-02 18:37:27] file1 - NEW
[2026-02-02 18:37:30] file1 - MODIFIED
```

7. How should backing up of empty directories be logged? (as in answer 5)

8. In problem1 of part B how would we know the value of Tk from n/2 to n-1 in the second half if the phase alignment formula is only till n/2-1. In each recursion are we supposed to be returning the current result?

9. In part(a) q1 detect ghost files, do we need to log a file missing from source only once or everytime when the script is run ?

10. If I initialize the project with uv then there will be some extra files in the directory like hello.py , main.py and pyproject.toml. Do i need to delete these files after uv init or kepping these files as it is fine ?

11. In part A problem 2, the .enc file is being decrypted by the generated checksum and is throwing bad decrypt error.

12. For Problem 2 Part A, after decrypting secret.enc into secret_revealed.jpg, should the resulting file be a valid, viewable image that opens in a standard image viewer? Or is not opening due to ‘bad decrypt’? 

13. For part(a) question 1 in copy_file function is the source and the destination (given as arguments), full paths of the source and destination files ? If so then, when calling the log function do i need to pass the whole source path (the given source file argument in the copy_file function) that will be given to the copy function or only the file name?

14. In part B q3, should the punctuations be just removed or replaced by a space, as in the text there are instances like sleep.that, which convert to a single word sleepthat on removing the punctuation?

15. In partB q3, the plot_frequency_vs_rank function prints to the stdout (`print(f"Saved plot: {filename}")`). Should we remove this line as the problem states to only print the analysis to the stdout?

16. In part B Q3, there are no bigrams or trigrams starting with fest. Is this intentional?

17. For the dry flag in q1 part (a), what are the outputs that we should print ? Also do we still need to log the data in backup.log even if we have the dry run flag ?

18. For question 1 part(a) do we need to log backup.log as ghost file as well ?

19. In part B Q2, should we plot the graphs using the training data or testing data?

20. In part A Q1, how should we log filename
`[2026-02-02 18:37:27] /home/source/folder1/example1.txt`
or
`[2026-02-02 18:37:27] folder1/example1.txt`
or
`[2026-02-02 18:37:27] example1.txt`

~~21. For Q1 part A , do we also need to show backup.log as a ghost file.~~ - look up 2cm gang

21. What is the expected output for the test script in Part B- Q2?

22. For part b q3 does starting with fest means first element of the tuple starts with "fest" or does it mean a key where one of the string starts with fest which will include "fest" and words like "festival" as well?

23. For questions like part b q2,q3 do we need to run the code and upload the files generated as well?

24. In q4 partB can i assume The prof has to leave the current building before entering another building ? and if the time elapsed has some seconds, how should the time_spent be calculated ? and if the prof has entered LIBRARY and has not exited so how will the time elapsed be calculated ?

25. For q5 partB should i modify this line "parser.add_argument("image", nargs="?", default="input_meme.jpg", help="Input image")" to change default to "secet_revealed.jpg" or should i change the name of secret_revealed.jpg to input_meme.jpg and what is the expected output of q5 ?

26. For q5 partB , when running the program i am getting this error "DeprecationWarning: Image.Image.getdata is deprecated and will be removed in Pillow 14 (2027-10-15). Use get_flattened_data instead. pixels = gray.getdata()" . Is this fine ?

27. For question 1 part A in the log function there is a comment  # Args: $1=message. What does this refer to. Is $1 not source directory. Also do we log while doing dry run.
