<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Uncategorized &#8211; CAPDIO</title>
	<atom:link href="https://www.capdio.com/category/uncategorized/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.capdio.com</link>
	<description>遊戲開發 Studio</description>
	<lastBuildDate>Fri, 10 Apr 2026 16:45:48 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>

<image>
	<url>https://www.capdio.com/wp-content/uploads/2024/06/cropped-capdio-favicon-white-32x32.png</url>
	<title>Uncategorized &#8211; CAPDIO</title>
	<link>https://www.capdio.com</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>docmost 為什麼中文搜尋會找不到內容</title>
		<link>https://www.capdio.com/uncategorized/docmost-%e7%82%ba%e4%bb%80%e9%ba%bc%e4%b8%ad%e6%96%87%e6%90%9c%e5%b0%8b%e6%9c%83%e6%89%be%e4%b8%8d%e5%88%b0%e5%85%a7%e5%ae%b9/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=docmost-%25e7%2582%25ba%25e4%25bb%2580%25e9%25ba%25bc%25e4%25b8%25ad%25e6%2596%2587%25e6%2590%259c%25e5%25b0%258b%25e6%259c%2583%25e6%2589%25be%25e4%25b8%258d%25e5%2588%25b0%25e5%2585%25a7%25e5%25ae%25b9</link>
					<comments>https://www.capdio.com/uncategorized/docmost-%e7%82%ba%e4%bb%80%e9%ba%bc%e4%b8%ad%e6%96%87%e6%90%9c%e5%b0%8b%e6%9c%83%e6%89%be%e4%b8%8d%e5%88%b0%e5%85%a7%e5%ae%b9/#respond</comments>
		
		<dc:creator><![CDATA[adcapdio]]></dc:creator>
		<pubDate>Fri, 10 Apr 2026 16:45:46 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://www.capdio.com/?p=1913</guid>

					<description><![CDATA[相信很多 docmnost 的新手用戶都會發現, 自己透過 docker 安裝架設好的 docmost 再進行中文搜尋的時候都找不到內容. 那是因為 postgres 的問題, 請照著站長的下方說明進行調整就可以解決了喔!!! 使用 Zhparser 來解決 PostgreSQL 中文全文檢索]]></description>
										<content:encoded><![CDATA[
<p>相信很多 docmnost 的新手用戶都會發現, 自己透過 docker 安裝架設好的 docmost 再進行中文搜尋的時候都找不到內容. 那是因為 postgres 的問題, 請照著站長的下方說明進行調整就可以解決了喔!!!</p>



<blockquote class="wp-block-quote is-layout-flow wp-block-quote-is-layout-flow">
<p>使用 Zhparser 來解決 PostgreSQL 中文全文檢索</p>
</blockquote>



<div class="hcb_wrap"><pre class="prism line-numbers lang-plain"><code># 先查看一下你要前往 postgres 的 container 是哪一個, 記下 id
docker ps -a

# 進入 container 並且停在 bash 的 shell(環境)畫面中
# 請將下方 container_id 換成你環境中的目標的 id
docker exec -it container_id bash

## 接下來要來安裝 Zhparser, 但是我們要先下載來編譯一下喔
# 首先, 確定一下你的 postgres 版本, 先登入到 postgres 裡面
# 登入 postgres, 帳號如果你是依照官方的文件安裝, 那應該是 docmost
# 或是你自己設定的其他帳號
psql -U docmost

# 輸入以下指令
SELECT VERSION();

# 板主這邊看到的是
 PostgreSQL 18.3 (Debian 18.3-1.pgdg13+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 14.2.0-19) 14.2.0, 64-bit

# 確認完版本之後, 請輸入 exit 跳出, 回到 bash 畫面

# 那麼我們就可以透過以下指令準備好相關的環境
apt update -y && apt install wget gcc make git bzip2 postgresql-server-dev-18 -y

# 接下來我們要下載 Zhparser, 版本的部分你可以查閱下方網址
https://www.xunsearch.com/scws/download.php

# 確認好版本之下就來進行以下步驟
cd /tmp
wget http://www.xunsearch.com/scws/down/scws-1.2.3.tar.bz2
tar -jxvf scws-1.2.3.tar.bz2 
cd scws-1.2.3
./configure && make && make install

cd ..
git clone https://github.com/amutu/zhparser.git
cd zhparser/
make && make install

# 完成之後, 請登入 postgres
psql -U docmost

# 輸入以下指令
CREATE EXTENSION zhparser;
CREATE TEXT SEARCH CONFIGURATION chinese (PARSER = zhparser);

# 完成後請退出
exit

# 接下來你可以回到 docmost 試試看中文搜尋是否可以作用了


</code></pre></div>
]]></content:encoded>
					
					<wfw:commentRss>https://www.capdio.com/uncategorized/docmost-%e7%82%ba%e4%bb%80%e9%ba%bc%e4%b8%ad%e6%96%87%e6%90%9c%e5%b0%8b%e6%9c%83%e6%89%be%e4%b8%8d%e5%88%b0%e5%85%a7%e5%ae%b9/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>來使用python + yfinance library 繪製特斯拉近期的股價吧</title>
		<link>https://www.capdio.com/uncategorized/%e4%be%86%e4%bd%bf%e7%94%a8python-yfinance-library-%e7%b9%aa%e8%a3%bd%e7%89%b9%e6%96%af%e6%8b%89%e8%bf%91%e6%9c%9f%e7%9a%84%e8%82%a1%e5%83%b9%e5%90%a7/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=%25e4%25be%2586%25e4%25bd%25bf%25e7%2594%25a8python-yfinance-library-%25e7%25b9%25aa%25e8%25a3%25bd%25e7%2589%25b9%25e6%2596%25af%25e6%258b%2589%25e8%25bf%2591%25e6%259c%259f%25e7%259a%2584%25e8%2582%25a1%25e5%2583%25b9%25e5%2590%25a7</link>
					<comments>https://www.capdio.com/uncategorized/%e4%be%86%e4%bd%bf%e7%94%a8python-yfinance-library-%e7%b9%aa%e8%a3%bd%e7%89%b9%e6%96%af%e6%8b%89%e8%bf%91%e6%9c%9f%e7%9a%84%e8%82%a1%e5%83%b9%e5%90%a7/#respond</comments>
		
		<dc:creator><![CDATA[adcapdio]]></dc:creator>
		<pubDate>Sat, 30 Aug 2025 08:26:20 +0000</pubDate>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://www.capdio.com/?p=1883</guid>

					<description><![CDATA[如果你對 python 還不熟的話, 可能建議你先學習一下 python, 有個基本功再來這邊喔!!! 當然完全不懂 python, 照著內文說明做, 誤打誤撞 &#8220;可能&#8221; 也會成功!! 事不宜遲我們先來準備一下相關環境吧!! 環境設定 首先你當然是會先有 python 的開發與執行環境對吧!! 好比說筆者這邊用的就是 PyCharm, 當然有些人會選擇 jupyter, 就看你自己習慣囉! 如果是 IDE, 你就可以再輸入 source code 時, 依依帶入所需要的 library, 如果是純文字模式, 那你可能就需要先安裝環境套見到你的電腦中. 首先我們先小試一下抓取資料 以下就是我們試著抓取美國 Tesla&#8230;]]></description>
										<content:encoded><![CDATA[
<p>如果你對 python 還不熟的話, 可能建議你先學習一下 python, 有個基本功再來這邊喔!!!  當然完全不懂 python, 照著內文說明做, 誤打誤撞 &#8220;可能&#8221; 也會成功!!  事不宜遲我們先來準備一下相關環境吧!!</p>



<hr class="wp-block-separator has-alpha-channel-opacity"/>



<h2 class="wp-block-heading">環境設定</h2>



<p>首先你當然是會先有 python 的開發與執行環境對吧!!  好比說筆者這邊用的就是 <a href="https://www.jetbrains.com/pycharm/" target="_blank" rel="noreferrer noopener">PyCharm</a>, 當然有些人會選擇 <a href="https://jupyter.org/" target="_blank" rel="noreferrer noopener">jupyter</a>, 就看你自己習慣囉! <br><br>如果是 IDE, 你就可以再輸入 source code 時, 依依帶入所需要的 library, 如果是純文字模式, 那你可能就需要先安裝環境套見到你的電腦中.</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-plain"><code># jupyter
!pip install yfinance

# terminal mode
pip install yfinance
# or, maybe 如果你的環境中有 python2 與 3 的時候 就會分 pip 與 pip3 兩種指令
pip3 install yfinance

# 其實我們還需要另外兩個 library
# numpy 與 pandas, 只是通常我們的環境內都有, 所以沒有特別提出來</code></pre></div>



<hr class="wp-block-separator has-alpha-channel-opacity"/>



<h2 class="wp-block-heading">首先我們先小試一下抓取資料</h2>



<p>以下就是我們試著抓取美國 Tesla 股價的一小段程式碼</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-plain"><code>import numpy as np
import pandas as pd

import yfinance as yf

my_data = yf.download(&#39;TSLA&#39;, start=&#39;2025-01-02&#39;, end=&#39;2025-07-02&#39;)
print(my_data.info)</code></pre></div>



<p>以上存檔執行後你就會看到類似以下畫面的結果, 當然這邊僅顯示一部分而已, 這僅是示意圖</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-plain"><code>            Close.      High        Low         Open        Volume
Date                                                                 
2025-01-02  379.279999  392.730011  373.040009  390.100006  109710700
2025-01-03  410.440002  411.880005  379.450012  381.480011   95423300
2025-01-06  411.049988  426.429993  401.700012  423.200012   85516500
2025-01-07  394.359985  414.329987  390.000000  405.829987   75699500
2025-01-08  394.940002  402.500000  387.399994  392.950012   73038800
...                ...         ...         ...         ...        ...
2025-06-25  327.549988  343.000000  320.399994  342.700012  119845100
2025-06-26  325.779999  331.049988  323.609985  324.609985   80440900
2025-06-27  323.630005  329.339996  317.500000  324.510010   89067000
2025-06-30  317.660004  325.579987  316.600006  319.899994   76695100
2025-07-01  300.709991  305.890015  293.209991  298.459991  145085700

[123 rows x 5 columns]&gt;</code></pre></div>



<p>這邊的程式碼有一段關鍵, 那就是 yf.download(&#8216;TSLA&#8217;, start=&#8217;2025-01-02&#8242;, end=&#8217;2025-07-02&#8242;)<br>TSLA 這是股價代號, 這個代號要怎麼查呢? 各位可以到 yahoo finance 的網站去查看, 搜尋到你要抓取的股票資訊後, 你可以查看網址列就會發現他的代號是多少了, 未來我再準備一篇查詢教學 <a href="https://www.capdio.com">building </a>!! <br>那麼後面那兩個參數就是一個是開始日期, 一個是結束日期. 應該很容易理解.</p>



<p>以下就是執行出來的結果<br><img fetchpriority="high" decoding="async" width="600" height="289" class="wp-image-1887" style="width: 600px;" src="https://www.capdio.com/wp-content/uploads/2025/08/tesla-scaled.jpg" alt="" srcset="https://www.capdio.com/wp-content/uploads/2025/08/tesla-scaled.jpg 2560w, https://www.capdio.com/wp-content/uploads/2025/08/tesla-300x145.jpg 300w, https://www.capdio.com/wp-content/uploads/2025/08/tesla-1024x494.jpg 1024w, https://www.capdio.com/wp-content/uploads/2025/08/tesla-768x370.jpg 768w, https://www.capdio.com/wp-content/uploads/2025/08/tesla-1536x740.jpg 1536w, https://www.capdio.com/wp-content/uploads/2025/08/tesla-2048x987.jpg 2048w, https://www.capdio.com/wp-content/uploads/2025/08/tesla-1920x925.jpg 1920w, https://www.capdio.com/wp-content/uploads/2025/08/tesla-1170x564.jpg 1170w, https://www.capdio.com/wp-content/uploads/2025/08/tesla-585x282.jpg 585w" sizes="(max-width: 600px) 100vw, 600px" /></p>



<p>最後我將 source code 列出如下, 歡迎大家拿去改喔!!!</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-plain"><code># For data manipulation
from datetime import datetime

import numpy as np
import pandas as pd

# To fetch financial data
import yfinance as yf

# For visualisation
import matplotlib.pyplot as plt
#print(plt.style.available)
#exit(0)
#plt.style.use(&#39;seaborn-darkgrid&#39;)
#plt.style.use(&#39;seaborn-v0_8-darkgrid&#39;)

# Set the ticker as &#39;EURUSD=X&#39;
endToday = datetime.today().strftime(&#39;%Y-%m-%d&#39;)
#forex_data = yf.download(&#39;EURUSD=X&#39;, start=&#39;2025-01-02&#39;, end=&#39;2021-12-31&#39;)
#forex_data = yf.download(&#39;EURUSD=X&#39;, start=&#39;2025-01-02&#39;, end=endToday)
forex_data = yf.download(&#39;TSLA&#39;, start=&#39;2025-01-02&#39;, end=endToday)
#forex_data = yf.download(&#39;TSLA&#39;, start=&#39;2025-01-02&#39;, end=&#39;2025-07-02&#39;)


print(forex_data.info)
#exit(0)
# Set the index to a datetime object
forex_data.index = pd.to_datetime(forex_data.index)

# Display the last five rows
#forex_data.tail()

# Plot the close price
plt.figure(figsize=(15, 7))
#forex_data[&#39;Adj Close&#39;].plot()

# 就是這一行讓繪圖先出現, 之後再呼叫 show 就出現一個空白的
#forex_data[&#39;Close&#39;].plot()
plt.plot(forex_data[&#39;Close&#39;])

# Set the title and axis label
plt.title(&#39;Tesla Data&#39;, fontsize=16)
plt.xlabel(&#39;Year-Month&#39;, fontsize=12)
plt.ylabel(&#39;Price&#39;, fontsize=12)
plt.xticks(fontsize=12)
plt.yticks(fontsize=12)
plt.legend([&#39;Close&#39;], prop={&#39;size&#39;: 12})

# Show the plot
plt.show()</code></pre></div>
]]></content:encoded>
					
					<wfw:commentRss>https://www.capdio.com/uncategorized/%e4%be%86%e4%bd%bf%e7%94%a8python-yfinance-library-%e7%b9%aa%e8%a3%bd%e7%89%b9%e6%96%af%e6%8b%89%e8%bf%91%e6%9c%9f%e7%9a%84%e8%82%a1%e5%83%b9%e5%90%a7/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>i++ 與 ++i 的差別是什麼？</title>
		<link>https://www.capdio.com/uncategorized/i-%e8%88%87-i-%e7%9a%84%e5%b7%ae%e5%88%a5%e6%98%af%e4%bb%80%e9%ba%bc%ef%bc%9f/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=i-%25e8%2588%2587-i-%25e7%259a%2584%25e5%25b7%25ae%25e5%2588%25a5%25e6%2598%25af%25e4%25bb%2580%25e9%25ba%25bc%25ef%25bc%259f</link>
					<comments>https://www.capdio.com/uncategorized/i-%e8%88%87-i-%e7%9a%84%e5%b7%ae%e5%88%a5%e6%98%af%e4%bb%80%e9%ba%bc%ef%bc%9f/#respond</comments>
		
		<dc:creator><![CDATA[George]]></dc:creator>
		<pubDate>Mon, 21 Jul 2025 03:24:00 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://www.capdio.com/?p=1773</guid>

					<description><![CDATA[PS: 如果你執行 node jsdemo.js 出錯, 那代表你的環境沒有 node.js 的執行環境. 請先進行設定後再回來執行 OK! 那麼為什麼 A 是 1. B 是 1, 但是 AA 卻是 0, BB 仍然是 1 呢?因為 A++ 代表 A = A + 1 的執行會在這一行結束後才進行.AA = A++&#8230;]]></description>
										<content:encoded><![CDATA[
<div class="hcb_wrap"><pre class="prism line-numbers lang-plain"><code># 首先不管在那一個現代化的 source code 當中我們常常會看到類似的寫法, 
# 但是他有什麼不同, 我們這邊就用一個簡單的例子來做說明
# 首先我們先來看一段程式碼, 這邊就先採用 python 來撰寫範例..... 等等 
# python 不支援 a++ 這樣的語法, 只能用 a += 1
# 好吧!!! 這邊就用 javascript 來當範例好了

nano jsdemo.js

# 內容如下
var A = 0;
var B = 0;
A++;
++B;
console.log(&quot;A: &quot; + A + &quot;, B: &quot; + B)

A = 0;
B = 0;
AA = A++;
BB = ++B;
console.log(&quot;AA: &quot; + AA + &quot;, BB: &quot; + BB)

# 存檔後, 直接執行
node jsdemo.js

# 我們看到輸出的是
A: 1, B: 1
AA: 0, BB: 1
</code></pre></div>



<p>PS: 如果你執行 node jsdemo.js 出錯, 那代表你的環境沒有 node.js 的執行環境. 請先進行設定後再回來執行</p>



<p>OK! 那麼為什麼 A 是 1. B 是 1, 但是 AA 卻是 0, BB 仍然是 1 呢?<br>因為 A++ 代表 A = A + 1 的執行會在這一行結束後才進行.<br>AA = A++ => AA = (0), A = 1;<br>而 ++B 則代表 B = B + 1 先執行後再帶入這一行的方程式<br>BB = ++B => BB = (0 + 1) => BB = 1, B = 1<br>有點類似 ++B => (B = B + 1), 括弧內要先執行的意思 </p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-plain"><code># 以下 js code 你可以自己試試看觀念是否正確喔!!
var A = 1;
var B = 1;
var AA = 0;
var BB = 0;

AA = A++ + A++;
BB = ++B + B++;

console.log(&quot;AA: &quot; + AA + &quot;, BB: &quot; + BB)

# 結果印出如下
AA: 3, BB: 4

# 以上為什麼是 3, 為什麼是 4. 解說如下
AA = (1) + (2) = 3 此行結束時的 A 已成為 3
BB = (2) + (2) = 4 此行結束時的 B 已成為 3
</code></pre></div>



<p>參考資料: https://ithelp.ithome.com.tw/articles/10192800</p>



<p></p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.capdio.com/uncategorized/i-%e8%88%87-i-%e7%9a%84%e5%b7%ae%e5%88%a5%e6%98%af%e4%bb%80%e9%ba%bc%ef%bc%9f/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>umount 時出現 Device is busy 的解決辦法</title>
		<link>https://www.capdio.com/uncategorized/umount-%e6%99%82%e5%87%ba%e7%8f%be-device-is-busy-%e7%9a%84%e8%a7%a3%e6%b1%ba%e8%be%a6%e6%b3%95/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=umount-%25e6%2599%2582%25e5%2587%25ba%25e7%258f%25be-device-is-busy-%25e7%259a%2584%25e8%25a7%25a3%25e6%25b1%25ba%25e8%25be%25a6%25e6%25b3%2595</link>
					<comments>https://www.capdio.com/uncategorized/umount-%e6%99%82%e5%87%ba%e7%8f%be-device-is-busy-%e7%9a%84%e8%a7%a3%e6%b1%ba%e8%be%a6%e6%b3%95/#respond</comments>
		
		<dc:creator><![CDATA[George]]></dc:creator>
		<pubDate>Thu, 03 Jul 2025 03:08:30 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[fuser]]></category>
		<category><![CDATA[lsof]]></category>
		<guid isPermaLink="false">https://www.capdio.com/?p=1824</guid>

					<description><![CDATA[當我們的 Linux 系統有設定掛載一些遠端的磁碟的時候, 如果你已經不需要他時想要進行卸載, 這個時候你可能會遇到系統告訴你, 該裝置正在忙碌, 無法卸載的狀況( Device is busy ). 那我們該怎麼解決呢? 參考資料:https://coldnew.github.io/d4a5e389/]]></description>
										<content:encoded><![CDATA[
<p>當我們的 Linux 系統有設定掛載一些遠端的磁碟的時候, 如果你已經不需要他時想要進行卸載, 這個時候你可能會遇到系統告訴你, 該裝置正在忙碌, 無法卸載的狀況( Device is busy ). 那我們該怎麼解決呢?</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-plain"><code># 首先會卡住不讓你卸載一定是因為有人正在使用該掛載目錄, 所以找出來結束他就是處理方向
# 方法 1, 使用 fuser, 如果發現無此指令的話可透過 &quot;apt-get install psmisc&quot; 安裝
# 如果我們掛載的資料匣是 /mntHere/, 則指令為
fuser -mv /mntHere/

# 接下來你會看到是哪一個 process ID 在使用它

# 那麼確定沒有還需要等待結束的 process 後, 我們就來將為結束且不需要的 process 關閉
fuser -kv /mntHere/

# 接下來可以再次查看有無其他的 process 使用它
fuser -mv /mntHere/

# 最後就直接卸載它吧
umount /mnthere/</code></pre></div>



<div class="hcb_wrap"><pre class="prism line-numbers lang-plain"><code># 方法 2, 使用 lsof
lsof /mntHere/

# 找出 process ID, 再將它們刪除即可卸載, 將以下指令的 processID 改為你自己查出的 ID 喔!
kill processID

# 最後就直接卸載它吧
umount /mnthere/</code></pre></div>



<p>參考資料:<br>https://coldnew.github.io/d4a5e389/</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.capdio.com/uncategorized/umount-%e6%99%82%e5%87%ba%e7%8f%be-device-is-busy-%e7%9a%84%e8%a7%a3%e6%b1%ba%e8%be%a6%e6%b3%95/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>smb 分享的 folder 怎麼連不上?</title>
		<link>https://www.capdio.com/uncategorized/smb-%e5%88%86%e4%ba%ab%e7%9a%84-folder-%e6%80%8e%e9%ba%bc%e9%80%a3%e4%b8%8d%e4%b8%8a/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=smb-%25e5%2588%2586%25e4%25ba%25ab%25e7%259a%2584-folder-%25e6%2580%258e%25e9%25ba%25bc%25e9%2580%25a3%25e4%25b8%258d%25e4%25b8%258a</link>
					<comments>https://www.capdio.com/uncategorized/smb-%e5%88%86%e4%ba%ab%e7%9a%84-folder-%e6%80%8e%e9%ba%bc%e9%80%a3%e4%b8%8d%e4%b8%8a/#respond</comments>
		
		<dc:creator><![CDATA[George]]></dc:creator>
		<pubDate>Tue, 26 Nov 2024 06:10:03 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://www.capdio.com/?p=1735</guid>

					<description><![CDATA[對於 samba 不熟的朋友時常會遇到這樣的問題, 那就是明明帳號密碼都設定好了, 透過 ssh 與 server 進行連線並使用帳號密碼為什麼可以連上沒有問題!!! 但古怪的是為什麼在別台電腦上(好比說 windows)要去 access 這個分享的資料匣卻無法正確連上去. 啊哈!! 原因就出在, samba 與 系統帳號 這兩組帳號是的一致的, 但密碼設定是不同地方的!! 不要混為一談喔!! 雖然說我們在 /etc/samba/smb.conf 設定好要分享的資料匣相關資料, 但還需透過 smbpasswd 設定帳號密碼, 才是正確設定 smbuser 所屬帳號密碼的管理指令!! 如果要從頭設定的話, 也可以參考另一篇完整的 SOP 喔!Linux Server,&#8230;]]></description>
										<content:encoded><![CDATA[
<p>對於 samba 不熟的朋友時常會遇到這樣的問題, 那就是明明帳號密碼都設定好了, 透過 ssh 與 server 進行連線並使用帳號密碼為什麼可以連上沒有問題!!! 但古怪的是為什麼在別台電腦上(好比說 windows)要去 access 這個分享的資料匣卻無法正確連上去.<br><br>啊哈!! 原因就出在, samba 與 系統帳號 這兩組帳號是的一致的, 但密碼設定是不同地方的!! 不要混為一談喔!! 雖然說我們在 /etc/samba/smb.conf 設定好要分享的資料匣相關資料, 但還需透過 smbpasswd 設定帳號密碼, 才是正確設定 smbuser 所屬帳號密碼的管理指令!!</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-plain"><code># 1. 設定一個分享目錄至samba的設定檔, 記得要使用 superuser 的權限喔
sudo vi /etc/samba/smb.conf

# 2. 設定內容給分享資料匣
[shareFolder]
path=/home/shareMan/shareFoler
browseable = yes
read only = no
writable = yes
valid users = joe, jane, tanaka, miko
# 以上應該不用說明了吧? 基本上應該很容易理解, 如有不清楚的歡迎留言

# 3. 設定 Samba 所需的使用者與密碼
# 剛剛在 samba 設定檔 smb.conf 內我們設定了4個使用者，但此使用者的密碼並不一定是Linux的系統帳號密碼

# 示範如下, 如果該帳號還沒有建立(系統帳號), 記得先透過以下指令建立喔!
# 設定不須登入/操作 Shell 的系統帳號 joe(範例), 這邊會問你要設定 &quot;系統密碼&quot; 為多少喔
sudo adduser joe --shell /bin/false

# 然後我們必需將這些使用者帳號在 samba 服務內的密碼進行設定、透過 smbpasswd 這個指令進行
# sudo smbpasswd -a &lt;UserName&gt;
sudo smbpasswd -a joe

# 4. Restart Samba service
sudo /etc/init.d/samba restart

# 5. 接下拉你可以到 winodws 或是別台想要登入這個分享俠的 nas, mac, linux 去試試看了!!</code></pre></div>



<p>如果要從頭設定的話, 也可以參考另一篇完整的 SOP 喔!<br><a href="https://www.capdio.com/servertech/linux/linux-server-how-to-share-folder-to-users-in-the-same-network/" data-type="post" data-id="1808">Linux Server, how to share folder to users in the same network</a></p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.capdio.com/uncategorized/smb-%e5%88%86%e4%ba%ab%e7%9a%84-folder-%e6%80%8e%e9%ba%bc%e9%80%a3%e4%b8%8d%e4%b8%8a/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>寫程式時想用代號去到表台灣各縣市該用什麼？</title>
		<link>https://www.capdio.com/uncategorized/%e5%af%ab%e7%a8%8b%e5%bc%8f%e6%99%82%e6%83%b3%e7%94%a8%e4%bb%a3%e8%99%9f%e5%8e%bb%e5%88%b0%e8%a1%a8%e5%8f%b0%e7%81%a3%e5%90%84%e7%b8%a3%e5%b8%82%e8%a9%b2%e7%94%a8%e4%bb%80%e9%ba%bc%ef%bc%9f/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=%25e5%25af%25ab%25e7%25a8%258b%25e5%25bc%258f%25e6%2599%2582%25e6%2583%25b3%25e7%2594%25a8%25e4%25bb%25a3%25e8%2599%259f%25e5%258e%25bb%25e5%2588%25b0%25e8%25a1%25a8%25e5%258f%25b0%25e7%2581%25a3%25e5%2590%2584%25e7%25b8%25a3%25e5%25b8%2582%25e8%25a9%25b2%25e7%2594%25a8%25e4%25bb%2580%25e9%25ba%25bc%25ef%25bc%259f</link>
		
		<dc:creator><![CDATA[George]]></dc:creator>
		<pubDate>Sun, 27 Oct 2024 14:28:24 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://www.capdio.com/?p=1750</guid>

					<description><![CDATA[台灣各縣市英文代號]]></description>
										<content:encoded><![CDATA[
<p>以下是整理出來的資料, 提供給大家參考!!</p>



<figure class="wp-block-table"><div class="pcrstb-wrap"><table class="has-fixed-layout"><tbody><tr><td>縣/市</td><td>分類</td><td>英文(通用拼英)</td><td>城市代碼</td></tr><tr><td>基隆市</td><td>市</td><td>Keelung City</td><td>KLU</td></tr><tr><td>新北市</td><td>直轄市</td><td>New Taipei City</td><td>TPH</td></tr><tr><td>臺北市</td><td>直轄市</td><td>Taipei City</td><td>TPE</td></tr><tr><td>桃園市</td><td>直轄市</td><td>Taoyuan City</td><td>TYC</td></tr><tr><td>新竹縣</td><td>縣</td><td>Hsinchu County</td><td>HSH</td></tr><tr><td>新竹市</td><td>市</td><td>Hsinchu City</td><td>HSC</td></tr><tr><td>苗栗市</td><td>市</td><td>Miaoli City</td><td>MAC</td></tr><tr><td>苗栗縣</td><td>縣</td><td>Miaoli County</td><td>MAL</td></tr><tr><td>臺中市</td><td>直轄市</td><td>Taichung City</td><td>TXG</td></tr><tr><td>彰化縣</td><td>縣</td><td>Changhua County</td><td>CWH</td></tr><tr><td>彰化市</td><td>市</td><td>Changhua City</td><td>CWS</td></tr><tr><td>南投市</td><td>市</td><td>Nantou City</td><td>NTC</td></tr><tr><td>南投縣</td><td>縣</td><td>Nantou County</td><td>NTO</td></tr><tr><td>雲林縣</td><td>縣</td><td>Yunlin County</td><td>YLH</td></tr><tr><td>嘉義縣</td><td>縣</td><td>Chiayi County</td><td>CHY</td></tr><tr><td>嘉義市</td><td>市</td><td>Chiayi City</td><td>CYI</td></tr><tr><td>臺南市</td><td>直轄市</td><td>Tainan City</td><td>TNN</td></tr><tr><td>高雄市</td><td>直轄市</td><td>Kaohsiung City</td><td>KHH</td></tr><tr><td>屏東縣</td><td>縣</td><td>Pingtung County</td><td>IUH</td></tr><tr><td>屏東市</td><td>市</td><td>Pingtung City</td><td>PTS</td></tr><tr><td>宜蘭縣</td><td>縣</td><td>Yilan County</td><td>ILN</td></tr><tr><td>宜蘭市</td><td>市</td><td>Yilan City</td><td>ILC</td></tr><tr><td>花蓮縣</td><td>縣</td><td>Hualien County</td><td>HWA</td></tr><tr><td>花蓮市</td><td>市</td><td>Hualien&nbsp; City</td><td>HWC</td></tr><tr><td>臺東市</td><td>市</td><td>Taitung City</td><td>TTC</td></tr><tr><td>臺東縣</td><td>縣</td><td>Taitung County</td><td>TTT</td></tr><tr><td>澎湖縣</td><td>縣</td><td>Penghu County</td><td>PEH</td></tr><tr><td>綠島</td><td>鄉</td><td>Green Island</td><td>GNI</td></tr><tr><td>蘭嶼</td><td>鄉</td><td>Orchid Island</td><td>KYD</td></tr><tr><td>金門縣</td><td>縣</td><td>Kinmen County</td><td>KMN</td></tr><tr><td>馬祖</td><td><strong><mark style="background-color:rgba(0, 0, 0, 0)" class="has-inline-color has-luminous-vivid-orange-color">真的沒有查到!!</mark></strong></td><td>Matsu</td><td>MZW</td></tr><tr><td>連江縣</td><td>縣</td><td>Lienchiang County</td><td>LNN</td></tr></tbody></table></div></figure>



<p></p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>java home 位置快速查看</title>
		<link>https://www.capdio.com/uncategorized/java-home-%e4%bd%8d%e7%bd%ae%e5%bf%ab%e9%80%9f%e6%9f%a5%e7%9c%8b/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=java-home-%25e4%25bd%258d%25e7%25bd%25ae%25e5%25bf%25ab%25e9%2580%259f%25e6%259f%25a5%25e7%259c%258b</link>
					<comments>https://www.capdio.com/uncategorized/java-home-%e4%bd%8d%e7%bd%ae%e5%bf%ab%e9%80%9f%e6%9f%a5%e7%9c%8b/#respond</comments>
		
		<dc:creator><![CDATA[George]]></dc:creator>
		<pubDate>Sun, 18 Aug 2024 03:35:52 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://www.capdio.com/?p=1733</guid>

					<description><![CDATA[有的時候不管我們在安裝什麼軟體或是在查環境參數文題時, 時常會需要查看一些資源的安裝位置, 這邊教大家一個快速查看 java 安裝位置的好方法!! 以 Mac( linux ) 為例, 輸入過後就會如下類似的顯示, 筆者這邊是用 skman 來管理 java, 所以輸出結果如下如果你的環境使用上有問題, 歡迎留言給筆者喔!!!! 參考資料: https://gist.github.com/thanoojgithub/10ff5a523b20c3a3256e318534dafe50]]></description>
										<content:encoded><![CDATA[
<p>有的時候不管我們在安裝什麼軟體或是在查環境參數文題時, 時常會需要查看一些資源的安裝位置, 這邊教大家一個快速查看 java 安裝位置的好方法!!  </p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-plain"><code>For Linux 與 macOS 可以透過以下指令獲取 java home 的位置:
    java -XshowSettings:properties -version 2&gt;&1 &gt; /dev/null | grep &#39;java.home&#39; 

And for Windows 則使用以下方法:
    java -XshowSettings:properties -version 2&gt;&1 | findstr &quot;java.home&quot;</code></pre></div>



<p>以 Mac( linux ) 為例, 輸入過後就會如下類似的顯示, 筆者這邊是用 skman 來管理 java, 所以輸出結果如下<br><img decoding="async" width="800" height="30" class="wp-image-1740" style="width: 800px;" src="https://www.capdio.com/wp-content/uploads/2024/08/ss.png" alt="" srcset="https://www.capdio.com/wp-content/uploads/2024/08/ss.png 1884w, https://www.capdio.com/wp-content/uploads/2024/08/ss-300x11.png 300w, https://www.capdio.com/wp-content/uploads/2024/08/ss-1024x38.png 1024w, https://www.capdio.com/wp-content/uploads/2024/08/ss-768x29.png 768w, https://www.capdio.com/wp-content/uploads/2024/08/ss-1536x57.png 1536w, https://www.capdio.com/wp-content/uploads/2024/08/ss-1170x43.png 1170w, https://www.capdio.com/wp-content/uploads/2024/08/ss-585x22.png 585w" sizes="(max-width: 800px) 100vw, 800px" /><br>如果你的環境使用上有問題, 歡迎留言給筆者喔!!!!</p>



<hr class="wp-block-separator has-alpha-channel-opacity"/>



<p>參考資料: https://gist.github.com/thanoojgithub/10ff5a523b20c3a3256e318534dafe50</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.capdio.com/uncategorized/java-home-%e4%bd%8d%e7%bd%ae%e5%bf%ab%e9%80%9f%e6%9f%a5%e7%9c%8b/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>做遊戲營運(運維)的人常常在說 (gross profit), (operating profit), (net income), 到底是在講什麼？</title>
		<link>https://www.capdio.com/uncategorized/%e5%81%9a%e9%81%8a%e6%88%b2%e7%87%9f%e9%81%8b%e9%81%8b%e7%b6%ad%e7%9a%84%e4%ba%ba%e5%b8%b8%e5%b8%b8%e5%9c%a8%e8%aa%aa-gross-profit-operating-profit-net-income-%e5%88%b0%e5%ba%95%e6%98%af/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=%25e5%2581%259a%25e9%2581%258a%25e6%2588%25b2%25e7%2587%259f%25e9%2581%258b%25e9%2581%258b%25e7%25b6%25ad%25e7%259a%2584%25e4%25ba%25ba%25e5%25b8%25b8%25e5%25b8%25b8%25e5%259c%25a8%25e8%25aa%25aa-gross-profit-operating-profit-net-income-%25e5%2588%25b0%25e5%25ba%2595%25e6%2598%25af</link>
					<comments>https://www.capdio.com/uncategorized/%e5%81%9a%e9%81%8a%e6%88%b2%e7%87%9f%e9%81%8b%e9%81%8b%e7%b6%ad%e7%9a%84%e4%ba%ba%e5%b8%b8%e5%b8%b8%e5%9c%a8%e8%aa%aa-gross-profit-operating-profit-net-income-%e5%88%b0%e5%ba%95%e6%98%af/#respond</comments>
		
		<dc:creator><![CDATA[George]]></dc:creator>
		<pubDate>Wed, 17 Jul 2024 10:14:34 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://www.capdio.com/?p=1708</guid>

					<description><![CDATA[我想首先我們還是來看看他的中文翻譯是什麼吧! Gross Profit, 毛利 or 毛利潤 Operating Profit, 營業利潤 Net Income, 淨利 or 淨利潤 不過在仔細說明這些之前, 我們還是要來了解一下操做遊戲營運時常會用到的一些名詞, 首先是 Revenue(收入); Revenue, 收入;, 就像是你買做柳一塊蛋糕, 然後拿出去賣 30 元, 那麼你的 revenue 就是 30, 你做蛋糕用的麵粉, 水電人力等未計入(成本), 所以只計收入是無法知道你到底是賺錢還是賠錢的喔! 毛利 or 毛利潤 好的,&#8230;]]></description>
										<content:encoded><![CDATA[
<p>我想首先我們還是來看看他的中文翻譯是什麼吧!</p>
<ul class="penci_list_shortcode penci_list-starlist">
<li>Gross Profit, 毛利 or 毛利潤</li>
<li>Operating Profit, 營業利潤</li>
<li>Net Income, 淨利 or 淨利潤</li>
</ul>
<p>不過在仔細說明這些之前, 我們還是要來了解一下操做遊戲營運時常會用到的一些名詞, 首先是 Revenue(收入);</p>
<ul class="penci_list_shortcode penci_list-starlist">
<li>Revenue, 收入;, 就像是你買做柳一塊蛋糕, 然後拿出去賣 30 元, 那麼你的 revenue 就是 30, 你做蛋糕用的麵粉, 水電人力等未計入(成本), 所以只計收入是無法知道你到底是賺錢還是賠錢的喔!</li>
</ul>
<h3>毛利 or 毛利潤</h3>
<p>好的, 了解以上簡單說明之後, 我們就可以來看一個簡單的公式, <span class="penci-highlighted-blue">毛利潤</span>是總收入减去跟出售商品的生産有關的費用, 好的這邊多一格專用術語, 銷售貨物的成本 (COGS, Cost Of Goods Sold), 或是簡稱 &#8220;銷貨成本&#8221;,  這邊要注意的是 COGS 包括直接的勞動力, 原物料成本, 以及與生産設施相關的製造費用(按比例認列, 不應是全部), 但也不包括間接的費用, 比如說公司辦公室與水電成本,  另外也不包括負債費用以及稅金.</p>
<h5>$$Gross \ Profit = {Revenue \ &#8211; \ Cost \ Of \ Goods Sold}$$</h5>
<p>&nbsp;</p>
<h3>營業利潤</h3>
<p>接下來就我們來看看營業利潤. <span class="penci-highlighted-blue">營業利潤</span>來自于毛利, 反映的是扣除所有營業成本後的剩餘收入. 也就是說, 除了 COGS 外, 其他扣除項還有固定成本的費用(財務報表中常見的項目), 比如說租金, 網路費用&#8230;等, 而可變費用, 比如說貨物運送產生的費用, 工資和水電(以上我們就用 Operating Expenses 來代表)，最後還有資産的攤提和折舊(Depreciation and Amortization). 維持企業運行必需的所有這些費用都必須包含在內. 營業利潤的計算公式如下：</p>
<h5>$$Operating \ Profit = {Gross \ Profile \ &#8211; \ Operating \ Expenses \ &#8211; \ depreciation \ and \  amortization}$$</h5>
<p>&nbsp;</p>
<p>營業利潤並不包含債務的利息, 稅費或投資收益, 他反映的是一家公司的經營盈利能力. 營業利潤也被稱爲稅息前利潤 (EBIT), 但後者包含非經營性收入. 如果一家公司沒有非經營性收入(好比說現金太多, 就會先將現金拿去銀行定存, 買ETF基金之類的), EBIT和營業利潤的數字就是相等的.<br />PS: EBIT, Earnings Before Interest and Taxes, 稅息前利潤.</p>
<p>&nbsp;</p>
<h3>淨利 or 淨利潤</h3>
<p>一家公司的利潤被稱爲<span class="penci-highlighted-blue">淨利潤 </span>(net income or net profit), 反映的是計算所有現金流後 total 的剩餘所得. 換句話說, 收入在計算所有所得 (income), 費用和成本後得到的就是淨利.</p>
<p>如果從營業利潤算起, 其他扣除項目還有負債費用, 比如說貸款利息, 以及稅金, 一次性非常規費用, 比如說設備採購費. 增加項目包括非主營業務（secondary operations）或投資産生的全部所得, 以及一次性付款, 比如說資産出售所得.</p>
<p>淨利潤無疑是最重要的財務指標, 反映的是一家公司爲所有者以及股東創造利潤的能力.</p>
<h3>以下我們用個簡單的例子來做個說明(搭配損益表)</h3>
<p>公司季度毛利潤$500萬, 就是收入的$600萬减去$100萬的COGS.<br />營業利潤$330萬，就是毛利潤的$500萬减去$170萬的營業費用 (total expenses).<br />淨利潤$300萬，也就是稅前利潤的$330萬减去$30萬的稅.</p>
<p><img decoding="async" src="https://www.capdio.com/wp-content/uploads/2024/07/Screenshot-2024-07-17-at-17.45.41-245x300.png" alt="" width="245" height="300" class="alignnone size-medium wp-image-1723" srcset="https://www.capdio.com/wp-content/uploads/2024/07/Screenshot-2024-07-17-at-17.45.41-245x300.png 245w, https://www.capdio.com/wp-content/uploads/2024/07/Screenshot-2024-07-17-at-17.45.41-768x941.png 768w, https://www.capdio.com/wp-content/uploads/2024/07/Screenshot-2024-07-17-at-17.45.41-585x717.png 585w, https://www.capdio.com/wp-content/uploads/2024/07/Screenshot-2024-07-17-at-17.45.41.png 790w" sizes="(max-width: 245px) 100vw, 245px" /></p>
<p>&nbsp;</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.capdio.com/uncategorized/%e5%81%9a%e9%81%8a%e6%88%b2%e7%87%9f%e9%81%8b%e9%81%8b%e7%b6%ad%e7%9a%84%e4%ba%ba%e5%b8%b8%e5%b8%b8%e5%9c%a8%e8%aa%aa-gross-profit-operating-profit-net-income-%e5%88%b0%e5%ba%95%e6%98%af/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>一間店面房地產的投資報酬率怎麼計算?</title>
		<link>https://www.capdio.com/uncategorized/%e4%b8%80%e9%96%93%e5%ba%97%e9%9d%a2%e6%88%bf%e5%9c%b0%e7%94%a2%e7%9a%84%e6%8a%95%e8%b3%87%e5%a0%b1%e9%85%ac%e7%8e%87%e6%80%8e%e9%ba%bc%e8%a8%88%e7%ae%97/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=%25e4%25b8%2580%25e9%2596%2593%25e5%25ba%2597%25e9%259d%25a2%25e6%2588%25bf%25e5%259c%25b0%25e7%2594%25a2%25e7%259a%2584%25e6%258a%2595%25e8%25b3%2587%25e5%25a0%25b1%25e9%2585%25ac%25e7%258e%2587%25e6%2580%258e%25e9%25ba%25bc%25e8%25a8%2588%25e7%25ae%2597</link>
					<comments>https://www.capdio.com/uncategorized/%e4%b8%80%e9%96%93%e5%ba%97%e9%9d%a2%e6%88%bf%e5%9c%b0%e7%94%a2%e7%9a%84%e6%8a%95%e8%b3%87%e5%a0%b1%e9%85%ac%e7%8e%87%e6%80%8e%e9%ba%bc%e8%a8%88%e7%ae%97/#respond</comments>
		
		<dc:creator><![CDATA[George]]></dc:creator>
		<pubDate>Tue, 16 Jul 2024 15:05:36 +0000</pubDate>
				<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://www.capdio.com/?p=1691</guid>

					<description><![CDATA[]]></description>
										<content:encoded><![CDATA[<p>[vc_row][vc_column][vc_column_text]店面房地產的投資報酬率 (Return on Investment, ROI) 通常用來評估投資的績效。2023 ~ 2024年的台灣房地產火熱, ETF更是創下募資的許多高標, 投資似乎是現代人的必修顯學, 不懂得投資那麼口袋裡的現金就會被通膨怪獸吃電! 那麼以下我們就來看看如果要買間捷運旁的店面該如何計算店面房地產投資報酬率, 其基本步驟如下：</p>



<ol class="wp-block-list">
<li style="list-style-type: none;">
<ol>
<li><strong>總收入 (Gross Income)</strong>：
<ul class="penci_list_shortcode penci_list-asterisklist">
<li>租金收入：租金每月收入乘以12。</li>
<li>其他收入：例如停車費、廣告費等。</li>
</ul>
<p>總收入=年租金收入+其他年收入</p>
</li>



<li><strong>總支出 (Total Expenses)</strong>：
<ul class="penci_list_shortcode penci_list-asterisklist">
<li>維修保養費用。</li>
<li>管理費用（若有）。</li>
<li>房產稅。</li>
<li>保險費用。</li>
<li>其他費用（例如水電、清潔等）。</li>
</ul>
<ul></ul>
<ul></ul>
<ul></ul>
<p>總支出=維修保養費用+管理費用+房產稅+保險費用+其他費用</p>
</li>



<li><strong>淨營運收入 (Net Operating Income, NOI)</strong>：<br />淨營運收入 = 總收入 − 總支出</li>



<li><strong>投資成本 (Investment Cost)</strong>：
<ul class="penci_list_shortcode penci_list-asterisklist">
<li>購買價格。</li>
<li>購買相關費用（如稅費、法律費用等）。</li>
<li>其他初始費用（如裝修費用）。</li>
</ul>
<ul></ul>
<p>投資成本 = 購買價格 + 購買相關費用 + 其他初始費用</p>
</li>



<li><strong>投資報酬率 (ROI)</strong>：<br />投資報酬率=(淨營運收入 / 投資成本) × 100%</li>
</ol>
</li>
</ol>
<p></p>



<h3 class="wp-block-heading">例子</h3>

<p>假設：</p>



<ul class="wp-block-list">
<li style="list-style-type: none;">
<ul class="penci_list_shortcode penci_list-heartlist">
<li>年租金收入：240,000元（每月20,000元）</li>



<li>其他年收入：10,000元</li>



<li>維修保養費用：20,000元</li>



<li>管理費用：15,000元</li>



<li>房產稅：10,000元</li>



<li>保險費用：5,000元</li>



<li>其他費用：5,000元</li>



<li>購買價格：3,000,000元</li>



<li>購買相關費用：100,000元</li>



<li>其他初始費用：50,000元</li>
</ul>
</li>
</ul>
<p></p>

<p>計算：</p>



<ol class="wp-block-list">
<li style="list-style-type: none;">
<ol>
<li>總收入 = 240,000 + 10,000 = 250,000元</li>



<li>總支出 = 20,000 + 15,000 + 10,000 + 5,000 + 5,000 = 55,000元</li>



<li>淨營運收入 = 250,000 &#8211; 55,000 = 195,000元</li>



<li>投資成本 = 3,000,000 + 100,000 + 50,000 = 3,150,000元</li>



<li>投資報酬率 = (195,000 / 3,150,000) × 100% ≈ 6.19%</li>
</ol>
</li>
</ol>
<p></p>

<p>因此，這個店面房地產的投資報酬率約為6.19%。 聽起來不錯對吧!! 趕緊募資來投資房地產？ 千萬小心, 還是那句老話, 如過事情這麼簡單, 怎會輪到我賺呢？ 您說是吧!!!!</p>
<p>[/vc_column_text][/vc_column][/vc_row]</p>]]></content:encoded>
					
					<wfw:commentRss>https://www.capdio.com/uncategorized/%e4%b8%80%e9%96%93%e5%ba%97%e9%9d%a2%e6%88%bf%e5%9c%b0%e7%94%a2%e7%9a%84%e6%8a%95%e8%b3%87%e5%a0%b1%e9%85%ac%e7%8e%87%e6%80%8e%e9%ba%bc%e8%a8%88%e7%ae%97/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>TypeScript 在變數後面加上 &#8220;!&#8221; 是什麼意思</title>
		<link>https://www.capdio.com/uncategorized/typescript-%e5%9c%a8%e8%ae%8a%e6%95%b8%e5%be%8c%e9%9d%a2%e5%8a%a0%e4%b8%8a-%e6%98%af%e4%bb%80%e9%ba%bc%e6%84%8f%e6%80%9d/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=typescript-%25e5%259c%25a8%25e8%25ae%258a%25e6%2595%25b8%25e5%25be%258c%25e9%259d%25a2%25e5%258a%25a0%25e4%25b8%258a-%25e6%2598%25af%25e4%25bb%2580%25e9%25ba%25bc%25e6%2584%258f%25e6%2580%259d</link>
					<comments>https://www.capdio.com/uncategorized/typescript-%e5%9c%a8%e8%ae%8a%e6%95%b8%e5%be%8c%e9%9d%a2%e5%8a%a0%e4%b8%8a-%e6%98%af%e4%bb%80%e9%ba%bc%e6%84%8f%e6%80%9d/#respond</comments>
		
		<dc:creator><![CDATA[George]]></dc:creator>
		<pubDate>Sun, 23 Jun 2024 07:47:30 +0000</pubDate>
				<category><![CDATA[JavaScript / TypeScript]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<guid isPermaLink="false">https://www.capdio.com/?p=1654</guid>

					<description><![CDATA[在 typescript 的程式語言當中, 使用 ! 驚嘆號的意思就是代表驚嘆號前方的變數(物件)必須是存在的, 如果不存在就會出錯!有點類似主動防呆的一種用法!!! 避免在這類高階程式語言當中因為將該變數(物件)進行指派或是初始化而造成看不到(不會跳錯誤)的 bug! 以下用個範例解釋! 輸出結果如下 參考資料來源: https://blog.csdn.net/qubes/article/details/136867140]]></description>
										<content:encoded><![CDATA[
<p>在 typescript 的程式語言當中, 使用 ! 驚嘆號的意思就是代表驚嘆號前方的變數(物件)必須是存在的, 如果不存在就會出錯!<br>有點類似主動防呆的一種用法!!! 避免在這類高階程式語言當中因為將該變數(物件)進行指派或是初始化而造成看不到(不會跳錯誤)的 bug!  以下用個範例解釋!</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-ts" data-lang="TypeScript"><code>function TS_test(inputObj: any): void{
    console.log(&quot;=====================================&quot;);
    // 完全正常的 case
    console.log(&#39;Best fruit name is: &#39; + inputObj.fruit!.name);
    // 因為沒有加上 ! ,所以並未強制判斷變數(物件)並要求跳出 error
    console.log(&#39;Case 1: Best food is: &#39; + inputObj.food);
    // 因為有加上 ! ,因此程式碼會判斷 food 是否存在, 不存在的話就會跳出 error
    console.log(&#39;Case 2: Best food is: &#39; + inputObj.food!.name);
    console.log(&quot;=====================================&quot;);
}

const TaiwanBest = {
    fruit: {name: &#39;banana&#39;}
}
TS_test(TaiwanBest);</code></pre></div>



<p>輸出結果如下</p>



<div class="hcb_wrap"><pre class="prism line-numbers lang-plain"><code>console.log(&#39;Case 2: Best food is: &#39; + inputObj.food!.name);

TypeError: Cannot read properties of undefined (reading &#39;name&#39;)</code></pre></div>



<p>參考資料來源: https://blog.csdn.net/qubes/article/details/136867140</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.capdio.com/uncategorized/typescript-%e5%9c%a8%e8%ae%8a%e6%95%b8%e5%be%8c%e9%9d%a2%e5%8a%a0%e4%b8%8a-%e6%98%af%e4%bb%80%e9%ba%bc%e6%84%8f%e6%80%9d/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
