← sources

I just gave an company's OA and just got rigged, help me with these questions below. Are they really for a fresher in devops?

source: reddit (reddit:devops)published 2026-07-29 17:33ingested 2026-07-30 08:25

retained text

<!-- SC_OFF --><div class="md"><p>Application version manager</p> <p>ABC is on a sprint spree and their development team is continuously rolling out new features and fixing bugs. The DevOps team now needs to ensure that the app updates are installed correctly for every user.</p> <p>Write a bash script that takes in the user’s current version preferably as a parameter, fetches all the versions which have database updates serially from a separate text file, and lists out the versions which need to be updated.</p> <p>Version format: major.minor.patch (eg- 2.5.23)</p> <p>Part 1</p> <p>Write a bash script where the current version and the latest version do not have a major update. Only minor versions or patch may vary.</p> <p>Eq- current version is 2.5.23, and latest version is 2.6.0</p> <p>Part 2</p> <p>In the same bash script file as for part 1 of the question, include changes so that it identifies changes in major version if any.</p> <p>Eq- current version is 2.5.23, and latest version is 3.1.2</p> <p>Input</p> <p>versions.txt (see filetree)</p> <p>Output</p> <p>If current version is 3.1.1</p> <p>3.1.6</p> <p>3.1.13</p> <p>If current version is 3.1.2</p> <p>3.1.6</p> <p>3.1.13</p> <p>If current version is 2.1.9</p> <p>2.1.10</p> <p>2.1.11</p> <p>2.1.18</p> <p>2.2.0</p> <p>2.2.10</p> <p>2.2.20</p> <p>2.4.5</p> <p>3.1.0</p> <p>3.1.1</p> <p>3.1.6</p> <p>3.1.13</p> </div><!-- SC_ON --> &#32; submitted by &#32; <a href="https://www.reddit.com/user/Glittering-Ear9274"> /u/Glittering-Ear9274 </a> <br /> <span><a href="https://www.reddit.com/r/devops/comments/1va32l4/i_just_gave_an_companys_oa_and_just_got_rigged/">[link]</a></span> &#32; <span><a href="https://www.reddit.com/r/devops/comments/1va32l4/i_just_gave_an_companys_oa_and_just_got_rigged/">[comments]</a></span>

document fetched 2026-07-30 08:25 · canonical https://reddit.com/r/devops/comments/1va32l4/i_just_gave_an_companys_oa_and_just_got_rigged