2010年12月24日 星期五

[php] 利用 Discuz 去做學校消息和相片發佈

首先去http://www.discuz.net/ 下載你要的版本, 通常都會下最新
下載完,要把discuz 安裝在你linux server 或 其他可以運行php 的上面

安裝好之後 在管理中心去選好你要的內容和版面
這樣就已經完成50%


因為學校有自己版面,所以要在自己版面顯示出
新有消息等等
所以要寫一個頁面,再用ifame 內陷這個頁面
這就我完成圖

當然在新的消息,要做一個會閃動的new 會更加好看



2010年12月23日 星期四

[JAVA] 中位數

import java.util.Scanner;
public class midnum {
public static void main{
Scanner numa = new Scanner(System.in);
Scanner numb = new Scanner(System.in);
Scanner numc = new Scanner(System.in);

int a=numa.nextInt();
int b=numb.nextInt();
int c=numc.nextInt();

if (a=>b){
    if (a<=c)
        System.out.println(a + "為中位數");
    else{
        if (b>=c)
            System.out.println(b + "為中位數");
        else
            System.out.println(c + "為中位數");
      }
}
else{
    if (b<=c)
        System.out.println(b + "為中位數");
    else{
        if (a>=c)
            System.out.println(a + "為中位數");
        else
            System.out.println(c + "為中位數");
     }
}
}


如果用>= 和<=  三數可以相同
如果用> 和 < 三數不可以相同

2010年12月12日 星期日