Online JudgeProblem SetAuthorsOnline ContestsUser
Web Board
Home Page
F.A.Qs
Statistical Charts
Problems
Submit Problem
Online Status
Prob.ID:
Register
Update your info
Authors ranklist
Current Contest
Past Contests
Scheduled Contests
Award Contest
User ID:
Password:
  Register

简单模拟题。。。

Posted by 274856653 at 2021-04-29 17:29:59 on Problem 1592
当type为C5的时候。。。page[row+i][col+j]字符为*时不可取代。但是。C5字符的某个位置为.时。 不更新对应page[row+i][col+j]的值。
当Type为C1的时候。可以直接重写对应位置的值。
void paintC5(int row, int col, char ch)
{
    int i, j;
    int num;

    if(ch == ' ')
        num = 26; 
    else
        num = ch - 'A';

    for(i = 0; i<5; i++)
        for(j = 0; j<6; j++)
        {   
            if( inrange(row+i, col+j) && page[row+i][col+j] != '*' && letter[num][i][j]!='.')
                page[row+i][col+j] = letter[num][i][j];
        }   
}

Followed by:

Post your reply here:
User ID:
Password:
Title:

Content:

Home Page   Go Back  To top


All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator