Tuesday, October 17, 2017

UVa problem solution 10189 - Minesweeper

problem link:

Discuss: in this problem you just have to simply check the adjacent square.if there is mine then just count it.for simplicity you can use function.then in loop you can print the sum.no need to store it string. use size_t to avoid presentation error.

try your self before see the code


Monday, October 16, 2017

UVa problem solution 489 - Hangman Judge

problem link:

Discuss: in this problem as you can count stroke only unique wrong guess you have to erase all duplicate element from guess string.you may can erase all duplicate element from string also as one correct guess for all same character.and this tricky part  that you can't short guess string using sorting method.and compare and follow the instruction of problem statement.


try yourself before see the code


Wednesday, October 4, 2017

UVa problem solution 119 - Greedy Gift Givers


problem link:


Discuss: In this problem you can easily use vector or structure to solve this problem.
and for presentation error you can use size_t.and there is no tricky part in this problem


try yourself before see the code