[Programmers.Io] ‘CHOCX’ Cake Inventory

โ€˜CHOCXโ€™ is a bakery specialized in chocolate cakes. Their cake formula is - each cake contains 40% Bread, 10% Sugar, 30% Cream, 20% chocolate. They accept order via mail for X kg cake. In response, they confirm if they can deliver the cake with a โ€œThank youโ€ or if they canโ€™t with a โ€œSorryโ€ note. When they respond they make sure, if any component is greater and equal to the required component, they retain 1 kg of each component Bread, Sugar, Cream, Chocolate in their inventory.

[Programmers.IO] minimum Assistance Problem

A finance company wants to hire some support assistance based upon their cases arrival and solved time but the company is confused with what is the minimum number of assistance required to handle the cases. Help the company to calculate minimum number to assistance can handle the cases. WAP to take input of 2 array/list (One for Case Arrival Time another of Case Solved Time), and your program should return the minimum number of assistance required for the company. Note: Assign assistance in such a way that no cases needed to be wait to arrive.

[Program][Kotlin]Rotate Array by N

import java.util.* fun main(args: Array<String>) { val scanner = Scanner(System.`in`) val a = IntArray(scanner.nextInt()) { scanner.nextInt() } var r = scanner.nextInt() if (r > a.size) r = r % a.size if (r != a.size) { repeat(r) { val last = a.last() var prev = a[0] var temp: Int for (i in 1..a.lastIndex) { temp = … Continue reading [Program][Kotlin]Rotate Array by N

[How-To][C#]Dynamically adding MenuItem and using Binding with viewModel

WPF's databinding is a powerful feature and I love how easy it becomes once you start to learn. so in my journey of MVVM, I had the requirement to use a WPF Menu Control, where I created Menu in XAML and then binded their commands via ViewModel, but I was Curious as if there was … Continue reading [How-To][C#]Dynamically adding MenuItem and using Binding with viewModel